/* 圆方之间π - Between Circle & Square π - 样式表 */

/* 主题变量 */
:root {
    /* 浅色主题变量 - 更现代化配色 */
    --primary-color: #6366f1;
    --primary-light: #818cf8;
    --primary-dark: #4f46e5;
    --secondary-color: #14b8a6;
    --secondary-light: #2dd4bf;
    --secondary-dark: #0d9488;
    --accent-color: #ec4899;
    --accent-light: #f472b6;
    --accent-dark: #db2777;
    --success-color: #10b981;
    --warning-color: #a78bfa;
    --danger-color: #ef4444;
    --background-color: #f8fafc;
    --surface-color: #ffffff;
    --card-background: rgba(255, 255, 255, 0.8);
    --text-color: #1e293b;
    --text-secondary: #64748b;
    --text-tertiary: #94a3b8;
    --text-accent: #6366f1;
    --point-inside-color: #f87171;
    --point-outside-color: #60a5fa;
    --border-radius-sm: 5px;
    --border-radius: 10px;
    --border-radius-lg: 16px;
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
    --shadow: 0 3px 7px rgba(0,0,0,0.07);
    --shadow-lg: 0 6px 18px rgba(0,0,0,0.09);
    --shadow-inner: inset 0 1px 2px rgba(0, 0, 0, 0.04);
    --transition-fast: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    --canvas-background: #FFFFFF;
    --grid-color: #e2e8f0;
    --chart-text: #64748b;
    --card-hover-transform: translateY(-8px);
    --glass-background: rgba(255, 255, 255, 0.7);
    --glass-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.1);
    --glass-border: 1px solid rgba(255, 255, 255, 0.18);
    --highlight-glow: 0 0 15px rgba(99, 102, 241, 0.3);
    --button-gradient: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    --card-gradient: linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.7));
    --header-gradient: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(236, 72, 153, 0.1));
    --primary-gradient: linear-gradient(135deg, var(--primary-light), var(--primary-dark));
    --secondary-gradient: linear-gradient(135deg, var(--secondary-light), var(--secondary-dark));
    --accent-gradient: linear-gradient(135deg, var(--accent-light), var(--accent-dark));
    /* RGB变量方便在透明度计算中使用 */
    --primary-color-rgb: 99, 102, 241;
    --accent-color-rgb: 236, 72, 153;
    --success-color-rgb: 16, 185, 129;
    --warning-color-rgb: 167, 139, 250;
    --card-padding: 18px;
    --section-gap: 20px;
    --header-height: 60px;
    --footer-height: 40px;
    --sidebar-width: 320px;
    --sidebar-width-lg: 280px;
    --right-panel-width-lg: 320px;
    --main-content-gap: 24px;
    /* 新增3D效果变量 */
    --logo-size: 70px;
    --orbit-size: 60px;
    --point-size: 6px;
    --orbit-speed: 8s;
    --orbit-color: rgba(255, 255, 255, 0.8);
    --interactive-bg-hover: rgba(var(--primary-color-rgb), 0.06);
    --interactive-border-hover: rgba(var(--primary-color-rgb), 0.2);
    --canvas-background-light: #ffffff;
    --canvas-background-dark: #0D121A;
    --grid-color-light: #e1e5e9;
    --grid-color-dark: #28303d;
    --chart-text-light: var(--text-secondary);
    --chart-text-dark: var(--text-secondary);
    --current-canvas-background: var(--canvas-background-light);
    --current-grid-color: var(--grid-color-light);
    --current-chart-text: var(--chart-text-light);
    --current-interactive-bg-hover: var(--interactive-bg-hover-light);
    --current-interactive-border-hover: var(--interactive-border-hover-light);
    --current-orbit-color: rgba(var(--primary-color-rgb), 0.6);
    --background-color-light: #f4f7f9;
    --surface-color-light: #ffffff;
    --background-color-dark: #0A0F14;
    --surface-color-dark: #10161F;
    --panel-border-color-light: rgba(0,0,0,0.08);
    --panel-border-color-dark: rgba(255,255,255,0.08);
}

/* 深色主题变量 */
html[data-theme='dark'] {
    --primary-color: #818cf8;
    --primary-light: #a5b4fc;
    --primary-dark: #6366f1;
    --secondary-color: #2dd4bf;
    --secondary-light: #5eead4;
    --secondary-dark: #14b8a6;
    --accent-color: #f472b6;
    --accent-light: #fb7185;
    --accent-dark: #ec4899;
    --success-color: #34d399;
    --warning-color: #c4b5fd;
    --danger-color: #f87171;
    --background-color: #0B101A;
    --surface-color: #111827;
    --card-background: rgba(30, 41, 59, 0.7);
    --text-color: #d1d5db;
    --text-secondary: #9ca3af;
    --text-tertiary: #6b7280;
    --text-accent: #a5b4fc;
    --point-inside-color: #fca5a5;
    --point-outside-color: #93c5fd;
    --shadow: 0 3px 8px rgba(0, 0, 0, 0.2);
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.12);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.25);
    --shadow-inner: inset 0 1px 2px rgba(0, 0, 0, 0.2);
    --canvas-background: #0D121C;
    --grid-color: #2c3548;
    --chart-text: var(--text-secondary);
    --glass-background: rgba(30, 41, 59, 0.7);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.25);
    --glass-border: 1px solid rgba(255, 255, 255, 0.08);
    --highlight-glow: 0 0 15px rgba(129, 140, 248, 0.3);
    --button-gradient: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    --card-gradient: linear-gradient(135deg, rgba(30, 41, 59, 0.8), rgba(30, 41, 59, 0.6));
    --header-gradient: linear-gradient(135deg, rgba(129, 140, 248, 0.15), rgba(236, 72, 153, 0.1));
    --orbit-color: rgba(165, 180, 252, 0.6);
    --interactive-bg-hover: rgba(var(--primary-color-rgb), 0.15);
    --interactive-border-hover: rgba(var(--primary-color-rgb), 0.4);
    --current-canvas-background: var(--canvas-background-dark);
    --current-grid-color: var(--grid-color-dark);
    --current-chart-text: var(--chart-text-dark);
    --current-interactive-bg-hover: var(--interactive-bg-hover-dark);
    --current-interactive-border-hover: var(--interactive-border-hover-dark);
    --current-orbit-color: rgba(165, 180, 252, 0.7);
    --current-background-color: var(--background-color-dark);
    --current-surface-color: var(--surface-color-dark);
    --panel-border-color-dark: rgba(255,255,255,0.08);
}

/* 基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--current-background-color);
    background-image: none;
    margin: 0;
    padding: 0;
    transition: var(--transition);
    overflow-x: hidden;
    min-height: 100vh;
    font-size: 14px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 全局导航栏 */
.global-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 0;
    margin: 0;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 24px;
    max-width: 1400px;
    margin: 0 auto;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-text {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-color);
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-menu {
    display: flex;
    gap: 8px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
    font-weight: 500;
    position: relative;
}

.nav-item:hover {
    background: rgba(var(--primary-color-rgb), 0.1);
    color: var(--primary-color);
    transform: translateY(-2px);
}

.nav-item.active {
    background: rgba(var(--primary-color-rgb), 0.15);
    color: var(--primary-color);
    font-weight: 600;
}

.nav-item.active::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 3px;
    background: var(--primary-gradient);
    border-radius: 2px;
}

.nav-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* 应用容器 */
.app-container {
    padding-top: 120px; /* 进一步增加为固定导航栏留出的空间 */
    min-height: 100vh;
    position: relative;
}

/* 页面容器 */
.page-container {
    display: none;
    min-height: calc(100vh - 120px);
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s cubic-bezier(0.22, 1, 0.36, 1);
    padding-top: 10px; /* 额外的安全间距 */
}

.page-container.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.page-container.entering {
    display: block;
    opacity: 0;
    transform: translateX(100%);
}

.page-container.leaving {
    opacity: 0;
    transform: translateX(-100%);
}

/* 欢迎页面样式 */
.welcome-hero {
    position: relative;
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: linear-gradient(135deg,
        rgba(var(--primary-color-rgb), 0.1) 0%,
        rgba(var(--accent-color-rgb), 0.05) 50%,
        rgba(var(--secondary-color-rgb), 0.1) 100%);
}

/* 数学公式背景装饰 */
.welcome-hero::after {
    content: 'π = 4 × (圆内点数/总点数)  ∫₀¹ √(1-x²) dx = π/4  lim(n→∞) Σ(4/n) = π  ∑ᵢ₌₁ⁿ 1/i² = π²/6';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: clamp(0.8rem, 1.5vw, 1.2rem);
    color: rgba(var(--primary-color-rgb), 0.08);
    font-family: 'Times New Roman', serif;
    white-space: pre-wrap;
    text-align: center;
    line-height: 3;
    pointer-events: none;
    z-index: 1;
    animation: floatFormulas 20s ease-in-out infinite;
}

@keyframes floatFormulas {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
        opacity: 0.08;
    }
    25% {
        transform: translateY(-10px) rotate(1deg);
        opacity: 0.12;
    }
    50% {
        transform: translateY(-5px) rotate(-1deg);
        opacity: 0.06;
    }
    75% {
        transform: translateY(-15px) rotate(0.5deg);
        opacity: 0.10;
    }
}

.particles-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 800px;
    padding: 40px 20px;
}

.hero-logo {
    position: relative;
    margin-bottom: 40px;
    display: inline-block;
}

.mega-pi-symbol {
    font-size: clamp(6rem, 15vw, 12rem);
    font-weight: 900;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px rgba(var(--primary-color-rgb), 0.3);
    animation: heroFloat 6s ease-in-out infinite;
    position: relative;
    z-index: 3;
}

.hero-orbit {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1;
}

.orbit-ring {
    position: absolute;
    border: 2px solid rgba(var(--primary-color-rgb), 0.3);
    border-radius: 50%;
    animation: orbitRotate 20s linear infinite;
}

.orbit-ring:nth-child(1) {
    width: 200px;
    height: 200px;
    margin: -100px 0 0 -100px;
    border-color: rgba(var(--primary-color-rgb), 0.4);
    animation-duration: 15s;
}

.orbit-ring:nth-child(2) {
    width: 300px;
    height: 300px;
    margin: -150px 0 0 -150px;
    border-color: rgba(var(--accent-color-rgb), 0.3);
    animation-duration: 25s;
    animation-direction: reverse;
}

.orbit-ring:nth-child(3) {
    width: 400px;
    height: 400px;
    margin: -200px 0 0 -200px;
    border-color: rgba(var(--secondary-color-rgb), 0.2);
    animation-duration: 35s;
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 4rem);
    margin-bottom: 20px;
    font-weight: 800;
    line-height: 1.2;
}

.hero-description {
    font-size: clamp(1.1rem, 2.5vw, 1.5rem);
    color: var(--text-secondary);
    margin-bottom: 40px;
    line-height: 1.6;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-actions {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-hero {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 32px;
    border: none;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.btn-hero.primary {
    background: var(--primary-gradient);
    color: white;
    box-shadow: 0 8px 25px rgba(var(--primary-color-rgb), 0.3);
}

.btn-hero.secondary {
    background: rgba(var(--primary-color-rgb), 0.1);
    color: var(--primary-color);
    border: 2px solid rgba(var(--primary-color-rgb), 0.3);
}

.btn-hero:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 15px 35px rgba(var(--primary-color-rgb), 0.4);
}

.btn-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.btn-hero:hover::before {
    left: 100%;
}

.welcome-features {
    padding: 80px 20px;
    background: rgba(var(--surface-color), 0.5);
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.feature-card {
    background: var(--glass-background);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: var(--glass-border);
    border-radius: var(--border-radius-lg);
    padding: 40px 30px;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--primary-gradient);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.feature-card:hover::before {
    transform: scaleX(1);
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(var(--primary-color-rgb), 0.15);
}

.feature-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    background: var(--primary-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
    box-shadow: 0 8px 20px rgba(var(--primary-color-rgb), 0.3);
}

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--text-color);
}

.feature-card p {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* 动画关键帧 */
@keyframes heroFloat {
    0%, 100% {
        transform: translateY(0px) scale(1);
        filter: drop-shadow(0 0 20px rgba(var(--primary-color-rgb), 0.3));
    }
    50% {
        transform: translateY(-20px) scale(1.02);
        filter: drop-shadow(0 0 30px rgba(var(--primary-color-rgb), 0.5));
    }
}

@keyframes orbitRotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes pulseGlow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(var(--primary-color-rgb), 0.3);
    }
    50% {
        box-shadow: 0 0 40px rgba(var(--primary-color-rgb), 0.6);
    }
}

@keyframes slideInFromBottom {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes textShimmer {
    0% {
        background-position: -200% center;
    }
    100% {
        background-position: 200% center;
    }
}

/* 增强的动画类 */
.animate-slide-up {
    animation: slideInFromBottom 0.8s ease-out forwards;
}

.animate-fade-scale {
    animation: fadeInScale 0.6s ease-out forwards;
}

.animate-delay-1 { animation-delay: 0.2s; }
.animate-delay-2 { animation-delay: 0.4s; }
.animate-delay-3 { animation-delay: 0.6s; }
.animate-delay-4 { animation-delay: 0.8s; }

/* 文字闪烁效果 */
.text-shimmer {
    background: linear-gradient(
        90deg,
        var(--text-color) 0%,
        var(--primary-color) 50%,
        var(--text-color) 100%
    );
    background-size: 200% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: textShimmer 3s ease-in-out infinite;
}

/* 高级动画效果 */
@keyframes morphingGlow {
    0%, 100% {
        box-shadow:
            0 0 20px rgba(var(--primary-color-rgb), 0.3),
            0 0 40px rgba(var(--primary-color-rgb), 0.1);
        filter: hue-rotate(0deg);
    }
    33% {
        box-shadow:
            0 0 30px rgba(var(--accent-color-rgb), 0.4),
            0 0 60px rgba(var(--accent-color-rgb), 0.15);
        filter: hue-rotate(120deg);
    }
    66% {
        box-shadow:
            0 0 25px rgba(var(--secondary-color-rgb), 0.35),
            0 0 50px rgba(var(--secondary-color-rgb), 0.12);
        filter: hue-rotate(240deg);
    }
}

@keyframes floatingElements {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
    }
    25% {
        transform: translateY(-10px) rotate(90deg);
    }
    50% {
        transform: translateY(-5px) rotate(180deg);
    }
    75% {
        transform: translateY(-15px) rotate(270deg);
    }
}

@keyframes dataFlow {
    0% {
        transform: translateX(-100%) scale(0.8);
        opacity: 0;
    }
    50% {
        opacity: 1;
        transform: translateX(0%) scale(1);
    }
    100% {
        transform: translateX(100%) scale(0.8);
        opacity: 0;
    }
}

@keyframes rippleEffect {
    0% {
        transform: scale(0);
        opacity: 1;
    }
    100% {
        transform: scale(4);
        opacity: 0;
    }
}

/* 增强的卡片动画 */
.enhanced-card {
    position: relative;
    overflow: hidden;
}

.enhanced-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: conic-gradient(
        from 0deg,
        transparent,
        rgba(var(--primary-color-rgb), 0.1),
        transparent,
        rgba(var(--accent-color-rgb), 0.1),
        transparent
    );
    animation: rotateGradient 8s linear infinite;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.enhanced-card:hover::before {
    opacity: 1;
}

@keyframes rotateGradient {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 粒子动画增强 */
.particle-enhanced {
    position: absolute;
    pointer-events: none;
    border-radius: 50%;
    animation: particleFloat 6s ease-in-out infinite;
}

.particle-enhanced:nth-child(odd) {
    animation-direction: reverse;
    animation-duration: 8s;
}

.particle-enhanced:nth-child(3n) {
    animation-duration: 10s;
    animation-delay: -2s;
}

@keyframes particleFloat {
    0%, 100% {
        transform: translateY(0px) translateX(0px) scale(1);
        opacity: 0.6;
    }
    25% {
        transform: translateY(-20px) translateX(10px) scale(1.2);
        opacity: 0.8;
    }
    50% {
        transform: translateY(-10px) translateX(-15px) scale(0.8);
        opacity: 1;
    }
    75% {
        transform: translateY(-30px) translateX(5px) scale(1.1);
        opacity: 0.7;
    }
}

/* 数据可视化动画 */
.data-visualization {
    position: relative;
    overflow: hidden;
}

.data-stream {
    position: absolute;
    width: 2px;
    height: 20px;
    background: linear-gradient(to bottom, transparent, var(--primary-color), transparent);
    animation: dataFlow 3s linear infinite;
}

.data-stream:nth-child(2n) {
    animation-delay: -1s;
    background: linear-gradient(to bottom, transparent, var(--accent-color), transparent);
}

.data-stream:nth-child(3n) {
    animation-delay: -2s;
    background: linear-gradient(to bottom, transparent, var(--secondary-color), transparent);
}

/* 交互式涟漪效果 */
.ripple-container {
    position: relative;
    overflow: hidden;
}

.ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(var(--primary-color-rgb), 0.3);
    transform: scale(0);
    animation: rippleEffect 0.6s linear;
    pointer-events: none;
}

/* 玻璃态效果 */
.glass {
    background: var(--glass-background);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: var(--border-radius);
    border: var(--glass-border);
    box-shadow: var(--glass-shadow);
}

/* 页面头部样式 */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 30px;
    margin: 20px 20px 30px 20px; /* 增加顶部间距避免被导航栏遮挡 */
    border-radius: var(--border-radius-lg);
}

.page-title h1 {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 8px;
}

.page-description {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin: 0 0 15px 0;
}

/* 数学公式样式 */
.math-formula {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: 'Times New Roman', serif;
    font-size: 1.3rem;
    color: var(--primary-color);
    background: rgba(var(--primary-color-rgb), 0.1);
    padding: 12px 20px;
    border-radius: var(--border-radius);
    border: 1px solid rgba(var(--primary-color-rgb), 0.2);
    backdrop-filter: blur(5px);
    animation: formulaGlow 3s ease-in-out infinite;
}

.formula-text {
    font-weight: 600;
}

.formula-fraction {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    font-size: 1rem;
}

.numerator {
    padding-bottom: 2px;
    border-bottom: 2px solid var(--primary-color);
    min-width: 80px;
    text-align: center;
    font-weight: 500;
}

.denominator {
    padding-top: 2px;
    min-width: 80px;
    text-align: center;
    font-weight: 500;
}

@keyframes formulaGlow {
    0%, 100% {
        box-shadow: 0 0 10px rgba(var(--primary-color-rgb), 0.2);
    }
    50% {
        box-shadow: 0 0 20px rgba(var(--primary-color-rgb), 0.4);
    }
}

/* 分析页面公式样式 */
.analysis-formulas {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-top: 15px;
}

.formula-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: linear-gradient(135deg,
        rgba(var(--accent-color-rgb), 0.1) 0%,
        rgba(var(--secondary-color-rgb), 0.05) 100%);
    border-radius: var(--border-radius-sm);
    border: 1px solid rgba(var(--accent-color-rgb), 0.2);
    font-family: 'Times New Roman', serif;
    transition: all 0.3s ease;
}

.formula-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(var(--accent-color-rgb), 0.2);
    border-color: rgba(var(--accent-color-rgb), 0.3);
}

.formula-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.formula-math {
    font-size: 1.1rem;
    color: var(--accent-color);
    font-weight: 600;
    font-style: italic;
}

.page-actions {
    display: flex;
    gap: 12px;
}

/* 分析页面样式 */
.analysis-content {
    padding: 10px 20px 40px 20px; /* 增加顶部间距 */
    position: relative;
}

/* 数学背景装饰 */
.analysis-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        radial-gradient(circle at 20% 30%, rgba(var(--primary-color-rgb), 0.03) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(var(--accent-color-rgb), 0.03) 0%, transparent 50%),
        linear-gradient(45deg, transparent 49%, rgba(var(--primary-color-rgb), 0.02) 50%, transparent 51%);
    pointer-events: none;
    z-index: 0;
}

.analysis-content > * {
    position: relative;
    z-index: 1;
}

.analysis-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 24px;
    max-width: 1400px;
    margin: 0 auto;
}

.analysis-card {
    background: var(--glass-background);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: var(--glass-border);
    border-radius: var(--border-radius-lg);
    padding: 24px;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
    overflow: hidden;
}

.analysis-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg,
        var(--primary-color) 0%,
        var(--accent-color) 50%,
        var(--secondary-color) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.analysis-card:hover::before {
    opacity: 1;
}

.analysis-card:hover {
    transform: translateY(-8px);
    box-shadow:
        0 20px 40px rgba(var(--primary-color-rgb), 0.15),
        0 0 0 1px rgba(var(--primary-color-rgb), 0.1);
}

/* 数学符号装饰 */
.analysis-card::after {
    content: '∫∑∏√∞';
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 0.7rem;
    color: rgba(var(--primary-color-rgb), 0.1);
    font-family: 'Times New Roman', serif;
    letter-spacing: 2px;
    pointer-events: none;
    transform: rotate(15deg);
}

.analysis-card.stats-overview {
    grid-column: span 2;
}

.analysis-card.chart-multi {
    grid-column: span 2;
    min-height: 400px;
}

.stats-dashboard {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    background: linear-gradient(135deg,
        rgba(var(--primary-color-rgb), 0.05) 0%,
        rgba(var(--accent-color-rgb), 0.03) 100%);
    border-radius: var(--border-radius);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(var(--primary-color-rgb), 0.1);
}

.stat-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,
        transparent,
        rgba(var(--primary-color-rgb), 0.1),
        transparent);
    transition: left 0.5s ease;
}

.stat-item:hover::before {
    left: 100%;
}

.stat-item:hover {
    background: linear-gradient(135deg,
        rgba(var(--primary-color-rgb), 0.1) 0%,
        rgba(var(--accent-color-rgb), 0.05) 100%);
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(var(--primary-color-rgb), 0.15);
    border-color: rgba(var(--primary-color-rgb), 0.2);
}

.stat-icon {
    width: 60px;
    height: 60px;
    background: var(--primary-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.6rem;
    flex-shrink: 0;
    position: relative;
    box-shadow:
        0 8px 20px rgba(var(--primary-color-rgb), 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

.stat-icon::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: conic-gradient(
        from 0deg,
        var(--primary-color),
        var(--accent-color),
        var(--secondary-color),
        var(--primary-color)
    );
    border-radius: 50%;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.stat-item:hover .stat-icon::before {
    opacity: 1;
}

.stat-item:hover .stat-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow:
        0 12px 30px rgba(var(--primary-color-rgb), 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.stat-content {
    flex: 1;
}

.stat-value {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
    line-height: 1;
    margin-bottom: 4px;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.chart-controls {
    display: flex;
    gap: 12px;
    align-items: center;
}

.chart-select, .strategy-select {
    padding: 8px 12px;
    border: 1px solid rgba(var(--primary-color-rgb), 0.2);
    border-radius: var(--border-radius-sm);
    background: var(--glass-background);
    color: var(--text-color);
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
}

.chart-select:hover, .strategy-select:hover {
    border-color: var(--primary-color);
    background: rgba(var(--primary-color-rgb), 0.05);
}

.table-container {
    max-height: 300px;
    overflow-y: auto;
    margin-top: 16px;
    border-radius: var(--border-radius);
    border: 1px solid rgba(var(--primary-color-rgb), 0.1);
}

.history-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.history-table th {
    background: rgba(var(--primary-color-rgb), 0.1);
    padding: 12px 8px;
    text-align: left;
    font-weight: 600;
    color: var(--text-color);
    border-bottom: 1px solid rgba(var(--primary-color-rgb), 0.2);
    position: sticky;
    top: 0;
    z-index: 10;
}

.history-table td {
    padding: 10px 8px;
    border-bottom: 1px solid rgba(var(--primary-color-rgb), 0.1);
    color: var(--text-secondary);
}

.history-table tbody tr:hover {
    background: rgba(var(--primary-color-rgb), 0.05);
}

.tuning-controls {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 16px;
}

.tuning-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.tuning-group label {
    font-weight: 600;
    color: var(--text-color);
    font-size: 0.95rem;
}

/* 发光效果 */
.glow {
    box-shadow: var(--highlight-glow);
}

/* 🚀 国奖级视觉效果 */

/* 3D数字跳动效果 */
.pi-counter {
    animation: numberPulse 1s ease-in-out infinite alternate;
    text-shadow: 
        0 0 10px rgba(var(--accent-color-rgb), 0.8),
        0 0 20px rgba(var(--accent-color-rgb), 0.6),
        0 0 30px rgba(var(--accent-color-rgb), 0.4);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.pi-counter.milestone {
    animation: milestoneFlash 2s ease-in-out;
    transform: scale(1.2);
}

@keyframes numberPulse {
    0% { 
        transform: scale(1) rotateY(0deg); 
        filter: hue-rotate(0deg);
    }
    100% { 
        transform: scale(1.05) rotateY(5deg); 
        filter: hue-rotate(30deg);
    }
}

@keyframes milestoneFlash {
    0%, 100% { 
        transform: scale(1) rotateY(0deg);
        text-shadow: 0 0 10px rgba(var(--accent-color-rgb), 0.8);
    }
    50% { 
        transform: scale(1.3) rotateY(180deg);
        text-shadow: 
            0 0 30px rgba(255, 215, 0, 1),
            0 0 60px rgba(255, 215, 0, 0.8),
            0 0 90px rgba(255, 215, 0, 0.6);
    }
}

/* 3D粒子爆炸容器 */
.particle-3d-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 10;
    overflow: hidden;
}

.particle-3d {
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    pointer-events: none;
}

.particle-explosion {
    animation: explode 2s ease-out forwards;
}

@keyframes explode {
    0% {
        opacity: 1;
        transform: scale(1) translate(0, 0);
    }
    100% {
        opacity: 0;
        transform: scale(0.2) translate(var(--dx, 200px), var(--dy, -200px));
    }
}

/* 成就弹窗 */
.achievement-popup {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(-100px);
    opacity: 0;
    z-index: 20;
    pointer-events: none;
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.achievement-popup.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
    animation: achievementBounce 3s ease-in-out;
}

.achievement-content {
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    color: #333;
    padding: 15px 25px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 
        0 10px 30px rgba(255, 215, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    border: 2px solid rgba(255, 255, 255, 0.2);
    font-weight: 700;
    font-size: 1.1rem;
}

.achievement-content i {
    font-size: 1.5rem;
    color: #ff6b35;
    animation: trophySpin 2s ease-in-out infinite;
}

@keyframes achievementBounce {
    0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
    40% { transform: translateX(-50%) translateY(-20px); }
    60% { transform: translateX(-50%) translateY(-10px); }
}

@keyframes trophySpin {
    0%, 100% { transform: rotate(0deg) scale(1); }
    25% { transform: rotate(-10deg) scale(1.1); }
    75% { transform: rotate(10deg) scale(1.1); }
}

/* 数值变化震撼效果 */
.data-value.major-change {
    animation: majorValueChange 1.5s ease-in-out;
}

@keyframes majorValueChange {
    0% { 
        transform: scale(1); 
        color: var(--text-accent);
        filter: hue-rotate(0deg);
    }
    30% { 
        transform: scale(1.3) rotateX(15deg); 
        color: #ff6b35;
        filter: hue-rotate(60deg);
        text-shadow: 0 0 20px currentColor;
    }
    100% { 
        transform: scale(1); 
        color: var(--text-accent);
        filter: hue-rotate(0deg);
    }
}

/* 精确度条震撼效果 */
.accuracy-bar.breakthrough {
    animation: accuracyBreakthrough 2s ease-in-out;
    box-shadow: 0 0 20px rgba(var(--success-color-rgb), 0.8);
}

@keyframes accuracyBreakthrough {
    0%, 100% { 
        transform: scaleY(1); 
        filter: brightness(1);
    }
    50% { 
        transform: scaleY(1.2); 
        filter: brightness(1.5) saturate(1.3);
        box-shadow: 0 0 30px rgba(var(--success-color-rgb), 1);
    }
}

/* 🤖 AI智能助手面板 */
.ai-assistant-panel {
    background: linear-gradient(135deg, rgba(var(--primary-color-rgb), 0.1), rgba(var(--accent-color-rgb), 0.05));
    border: 1px solid rgba(var(--primary-color-rgb), 0.2);
    border-radius: var(--border-radius);
    padding: 16px;
    margin-bottom: 20px;
    position: relative;
    overflow: hidden;
}

.ai-assistant-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(var(--primary-color-rgb), 0.1), transparent);
    animation: aiScan 3s infinite;
}

@keyframes aiScan {
    0% { left: -100%; }
    100% { left: 100%; }
}

.ai-assistant-panel h4 {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--primary-color);
    font-size: 1.1rem;
    margin-bottom: 12px;
    font-weight: 600;
}

.ai-assistant-panel h4 i {
    font-size: 1.3rem;
    animation: aiPulse 2s ease-in-out infinite;
}

@keyframes aiPulse {
    0%, 100% { 
        color: var(--primary-color); 
        transform: scale(1);
    }
    50% { 
        color: var(--accent-color); 
        transform: scale(1.1);
    }
}

.ai-prediction {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.ai-status {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.ai-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--success-color);
    animation: aiIndicator 1.5s ease-in-out infinite;
}

@keyframes aiIndicator {
    0%, 100% { 
        opacity: 1; 
        transform: scale(1);
        background: var(--success-color);
    }
    50% { 
        opacity: 0.3; 
        transform: scale(1.3);
        background: var(--primary-color);
    }
}

.ai-suggestion {
    background: rgba(var(--primary-color-rgb), 0.08);
    border: 1px solid rgba(var(--primary-color-rgb), 0.15);
    border-radius: 8px;
    padding: 12px;
    font-size: 0.95rem;
    color: var(--text-color);
    position: relative;
    line-height: 1.4;
}

.ai-suggestion::before {
    content: '💡';
    position: absolute;
    top: 8px;
    right: 8px;
    font-size: 1.2rem;
    animation: bulbGlow 2s ease-in-out infinite;
}

@keyframes bulbGlow {
    0%, 100% { 
        opacity: 0.6; 
        transform: scale(1);
    }
    50% { 
        opacity: 1; 
        transform: scale(1.2);
    }
}

.ai-prediction-box {
    background: rgba(var(--accent-color-rgb), 0.05);
    border: 1px solid rgba(var(--accent-color-rgb), 0.15);
    border-radius: 8px;
    padding: 10px;
}

.ai-prediction-box label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    display: block;
    margin-bottom: 6px;
}

.prediction-display {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.prediction-display span {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--accent-color);
    text-shadow: 0 0 10px rgba(var(--accent-color-rgb), 0.3);
}

.prediction-display small {
    font-size: 0.8rem;
    color: var(--text-tertiary);
}

#applyAITips {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    border: none;
    color: white;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

#applyAITips::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
    transform: translate(-50%, -50%);
}

#applyAITips:hover::before {
    width: 100px;
    height: 100px;
}

#applyAITips:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 8px 25px rgba(var(--primary-color-rgb), 0.4);
}

#applyAITips i {
    margin-right: 6px;
    animation: magicSpark 1.5s ease-in-out infinite;
}

@keyframes magicSpark {
    0%, 100% { 
        transform: rotate(0deg) scale(1); 
    }
    50% { 
        transform: rotate(180deg) scale(1.2); 
    }
}

/* 🚀 社交分享和截图功能 */
.share-section {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid rgba(var(--primary-color-rgb), 0.15);
    display: flex;
    gap: 8px;
}

.share-btn {
    background: linear-gradient(135deg, #1DA1F2, #1991DA);
    color: white;
    border: none;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

.share-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.6s;
}

.share-btn:hover::before {
    left: 100%;
}

.share-btn:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 8px 25px rgba(29, 161, 242, 0.4);
}

/* 分享弹窗 */
.share-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.share-modal.active {
    opacity: 1;
    visibility: visible;
}

.share-modal-content {
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-lg);
    padding: 30px;
    max-width: 500px;
    width: 90%;
    transform: scale(0.8) translateY(50px);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.share-modal.active .share-modal-content {
    transform: scale(1) translateY(0);
}

.share-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.share-modal-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-color);
    display: flex;
    align-items: center;
    gap: 10px;
}

.share-close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.share-close-btn:hover {
    background: rgba(var(--danger-color-rgb), 0.1);
    color: var(--danger-color);
    transform: rotate(90deg);
}

.share-preview {
    background: rgba(var(--primary-color-rgb), 0.05);
    border: 1px solid rgba(var(--primary-color-rgb), 0.15);
    border-radius: var(--border-radius);
    padding: 20px;
    margin-bottom: 20px;
    text-align: center;
}

.share-achievement-text {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 10px;
    text-shadow: 0 0 10px rgba(var(--primary-color-rgb), 0.3);
}

.share-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin: 15px 0;
}

.share-stat {
    text-align: center;
    padding: 10px;
    background: rgba(var(--accent-color-rgb), 0.1);
    border-radius: var(--border-radius-sm);
}

.share-stat-value {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--accent-color);
}

.share-stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-top: 5px;
}

.share-buttons {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

.social-share-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 15px;
    border: none;
    border-radius: var(--border-radius);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    font-size: 0.9rem;
}

.social-share-btn.weibo {
    background: #E6162D;
    color: white;
}

.social-share-btn.wechat {
    background: #07C160;
    color: white;
}

.social-share-btn.copy {
    background: var(--primary-gradient);
    color: white;
}

.social-share-btn.download {
    background: #8B5CF6;
    color: white;
}

.social-share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* QR码容器 */
.qr-container {
    display: none;
    text-align: center;
    margin-top: 15px;
}

.qr-container.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

#qrcode {
    display: inline-block;
    padding: 10px;
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
}

/* 🎮 游戏化排行榜元素 */
.leaderboard-mini {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.1), rgba(255, 193, 7, 0.05));
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: var(--border-radius);
    padding: 15px;
    margin-top: 15px;
}

.leaderboard-mini h4 {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.1rem;
    color: #ff8f00;
    margin-bottom: 10px;
}

.leaderboard-mini h4 i {
    animation: crownSpin 3s ease-in-out infinite;
}

@keyframes crownSpin {
    0%, 100% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(5deg) scale(1.1); }
}

.leaderboard-entry {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 10px;
    margin-bottom: 5px;
    background: rgba(255, 215, 0, 0.1);
    border-radius: var(--border-radius-sm);
    transition: all 0.3s ease;
}

.leaderboard-entry:hover {
    background: rgba(255, 215, 0, 0.2);
    transform: translateX(5px);
}

.leaderboard-rank {
    font-weight: 700;
    color: #ff8f00;
    width: 20px;
}

.leaderboard-name {
    flex: 1;
    font-weight: 600;
    color: var(--text-color);
}

.leaderboard-score {
    font-weight: 700;
    color: var(--accent-color);
    font-size: 0.9rem;
}

/* 当前用户高亮 */
.leaderboard-entry.current-user {
    background: linear-gradient(135deg, rgba(var(--primary-color-rgb), 0.2), rgba(var(--accent-color-rgb), 0.1));
    border: 1px solid rgba(var(--primary-color-rgb), 0.3);
    transform: scale(1.02);
}

.leaderboard-entry.current-user .leaderboard-name {
    color: var(--primary-color);
    font-weight: 700;
}

/* 徽章系统 */
.badge-collection {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
    margin-top: 10px;
}

.achievement-badge {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    position: relative;
    cursor: pointer;
    transition: all 0.3s ease;
}

.achievement-badge.gold {
    background: linear-gradient(135deg, #FFD700, #FFA500);
    color: #8B4513;
}

.achievement-badge.silver {
    background: linear-gradient(135deg, #C0C0C0, #A0A0A0);
    color: #404040;
}

.achievement-badge.bronze {
    background: linear-gradient(135deg, #CD7F32, #A0522D);
    color: #8B4513;
}

.achievement-badge:hover {
    transform: scale(1.3) rotate(10deg);
    z-index: 10;
}

/* 徽章工具提示 */
.achievement-badge::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: -35px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.9);
    color: white;
    padding: 5px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 1000;
}

.achievement-badge:hover::after {
    opacity: 1;
}

/* 🎓 教学页面样式 */
.tutorial-section {
    margin-bottom: 30px;
}

.principle-explanation {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    align-items: start;
}

.geometry-demo {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.unit-square {
    width: 200px;
    height: 200px;
    border: 3px solid var(--primary-color);
    position: relative;
    background: rgba(var(--primary-color-rgb), 0.05);
    border-radius: 8px;
}

.inscribed-circle {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 200px;
    height: 200px;
    border: 3px solid var(--accent-color);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    background: rgba(var(--accent-color-rgb), 0.05);
}

.demo-points {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.formula-steps {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.formula-step {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 15px;
    background: rgba(var(--primary-color-rgb), 0.05);
    border-radius: var(--border-radius);
    border-left: 4px solid var(--primary-color);
}

.formula-step.highlight {
    background: rgba(var(--accent-color-rgb), 0.1);
    border-left-color: var(--accent-color);
}

.step-number {
    width: 30px;
    height: 30px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    flex-shrink: 0;
}

.formula-step.highlight .step-number {
    background: var(--accent-color);
}

.interactive-demo {
    margin-top: 30px;
}

.demo-canvas-container {
    position: relative;
    display: inline-block;
    margin-bottom: 20px;
}

.demo-overlay {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 12px;
    border-radius: 8px;
    font-size: 0.9rem;
}

.stat-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
    min-width: 180px;
}

.stat-label {
    margin-right: 10px;
}

.stat-value {
    font-weight: bold;
    color: var(--accent-color);
}

.demo-controls {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.control-row {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.control-row label {
    font-weight: 600;
    min-width: 80px;
}

.history-timeline {
    display: flex;
    flex-direction: column;
    gap: 25px;
    position: relative;
    padding-left: 40px;
}

.history-timeline::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(to bottom, var(--primary-color), var(--accent-color));
    border-radius: 2px;
}

.timeline-item {
    position: relative;
    background: var(--glass-background);
    border: var(--glass-border);
    border-radius: var(--border-radius);
    padding: 20px;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -32px;
    top: 20px;
    width: 12px;
    height: 12px;
    background: var(--primary-color);
    border-radius: 50%;
    border: 3px solid var(--background-color);
}

.timeline-year {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.timeline-content h4 {
    margin-bottom: 8px;
    color: var(--text-color);
}

.timeline-content p {
    color: var(--text-secondary);
    line-height: 1.6;
}

.applications-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.application-card {
    background: var(--glass-background);
    border: var(--glass-border);
    border-radius: var(--border-radius);
    padding: 20px;
    text-align: center;
    transition: all 0.3s ease;
}

.application-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.app-icon {
    font-size: 3rem;
    margin-bottom: 15px;
}

.application-card h4 {
    margin-bottom: 10px;
    color: var(--text-color);
}

.application-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 10px;
}

.app-example {
    font-size: 0.85rem;
    color: var(--primary-color);
    font-style: italic;
}

/* 🏆 成就中心样式 */
.user-overview {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 25px;
    align-items: center;
    margin-bottom: 30px;
}

.user-avatar {
    position: relative;
}

.avatar-circle {
    width: 80px;
    height: 80px;
    background: var(--primary-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
    position: relative;
}

.level-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: var(--accent-color);
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: bold;
    border: 3px solid var(--background-color);
}

.user-info {
    flex: 1;
}

.user-info h3 {
    font-size: 1.4rem;
    margin-bottom: 10px;
    color: var(--text-color);
}

.exp-bar-container {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.exp-bar {
    height: 10px;
    background: rgba(var(--primary-color-rgb), 0.2);
    border-radius: 5px;
    overflow: hidden;
}

.exp-fill {
    height: 100%;
    background: var(--primary-gradient);
    transition: width 0.8s ease;
}

.exp-text {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.user-stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.stat-card {
    text-align: center;
    padding: 12px;
    background: rgba(var(--accent-color-rgb), 0.1);
    border-radius: var(--border-radius-sm);
}

.stat-card .stat-number {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--accent-color);
}

.stat-card .stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-top: 5px;
}

.achievement-filters {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 8px 16px;
    background: rgba(var(--primary-color-rgb), 0.1);
    border: 1px solid rgba(var(--primary-color-rgb), 0.2);
    border-radius: var(--border-radius-sm);
    color: var(--text-color);
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn.active,
.filter-btn:hover {
    background: var(--primary-color);
    color: white;
}

.achievements-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.achievement-item {
    display: flex;
    gap: 15px;
    padding: 20px;
    background: var(--glass-background);
    border: var(--glass-border);
    border-radius: var(--border-radius);
    transition: all 0.3s ease;
}

.achievement-item.locked {
    opacity: 0.6;
    filter: grayscale(50%);
}

.achievement-item.unlocked {
    border-color: rgba(var(--accent-color-rgb), 0.3);
    box-shadow: 0 0 20px rgba(var(--accent-color-rgb), 0.1);
}

.achievement-item:hover {
    transform: translateY(-2px);
}

.achievement-icon {
    font-size: 2.5rem;
    flex-shrink: 0;
}

.achievement-info {
    flex: 1;
}

.achievement-info h4 {
    margin-bottom: 5px;
    color: var(--text-color);
}

.achievement-info p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 10px;
}

.status-unlocked {
    color: var(--success-color);
    font-weight: 600;
}

.status-locked {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.records-tabs {
    display: flex;
    gap: 5px;
    margin-bottom: 20px;
    background: rgba(var(--primary-color-rgb), 0.05);
    border-radius: var(--border-radius);
    padding: 5px;
}

.record-tab {
    flex: 1;
    padding: 10px 16px;
    background: transparent;
    border: none;
    border-radius: var(--border-radius-sm);
    color: var(--text-color);
    cursor: pointer;
    transition: all 0.3s ease;
}

.record-tab.active {
    background: var(--primary-color);
    color: white;
}

.record-panel {
    display: none;
}

.record-panel.active {
    display: block;
}

/* 🚧 开发中页面样式 */
.coming-soon-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 400px;
    padding: 40px 20px;
}

.coming-soon-content {
    text-align: center;
    max-width: 500px;
    padding: 40px 30px;
}

.coming-soon-icon {
    font-size: 4rem;
    margin-bottom: 20px;
    opacity: 0.8;
}

.coming-soon-content h2 {
    font-size: 2rem;
    color: var(--text-color);
    margin-bottom: 15px;
}

.coming-soon-content p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 25px;
    line-height: 1.6;
}

.dev-progress {
    margin-bottom: 30px;
}

.progress-bar {
    height: 8px;
    background: rgba(var(--primary-color-rgb), 0.2);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 8px;
}

.progress-fill {
    height: 100%;
    background: var(--primary-gradient);
    transition: width 1s ease;
}

.progress-text {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.features-preview {
    background: rgba(var(--primary-color-rgb), 0.05);
    border-radius: var(--border-radius);
    padding: 20px;
    margin-bottom: 25px;
}

.features-preview h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

.features-preview ul {
    list-style: none;
    padding: 0;
    text-align: left;
}

.features-preview li {
    padding: 5px 0;
    color: var(--text-secondary);
    border-bottom: 1px solid rgba(var(--primary-color-rgb), 0.1);
}

.features-preview li:last-child {
    border-bottom: none;
}

/* 📊 算法对比页面样式 */
.algorithm-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.algorithm-card {
    background: var(--glass-background);
    border: var(--glass-border);
    border-radius: var(--border-radius);
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.algorithm-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(var(--primary-color-rgb), 0.1), transparent);
    transition: left 0.6s;
}

.algorithm-card:hover::before {
    left: 100%;
}

.algorithm-card.active {
    border-color: var(--primary-color);
    box-shadow: 0 0 20px rgba(var(--primary-color-rgb), 0.2);
}

.algorithm-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.algorithm-icon {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 15px;
    opacity: 0.8;
}

.algorithm-info {
    margin-bottom: 15px;
}

.algorithm-info h4 {
    font-size: 1.3rem;
    color: var(--text-color);
    margin-bottom: 8px;
}

.algorithm-info p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 12px;
    line-height: 1.4;
}

.algorithm-stats {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.algorithm-stats span {
    font-size: 0.85rem;
    color: var(--text-secondary);
    background: rgba(var(--primary-color-rgb), 0.1);
    padding: 4px 8px;
    border-radius: var(--border-radius-sm);
}

.algorithm-status {
    text-align: center;
    padding: 8px 12px;
    border-radius: var(--border-radius-sm);
    font-weight: 600;
    font-size: 0.9rem;
}

.algorithm-status:not(.coming-soon) {
    background: var(--success-color);
    color: white;
}

.algorithm-status.coming-soon {
    background: rgba(var(--warning-color-rgb), 0.2);
    color: var(--warning-color);
    border: 1px solid rgba(var(--warning-color-rgb), 0.3);
}

.comparison-container {
    margin-top: 20px;
}

.comparison-controls {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 25px;
    padding: 20px;
    background: rgba(var(--primary-color-rgb), 0.05);
    border-radius: var(--border-radius);
}

.control-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.control-group label {
    font-weight: 600;
    color: var(--text-color);
    min-width: 80px;
}

.control-group select {
    padding: 8px 12px;
    border: 1px solid rgba(var(--primary-color-rgb), 0.3);
    border-radius: var(--border-radius-sm);
    background: var(--background-color);
    color: var(--text-color);
}

.comparison-results {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    align-items: start;
}

.results-table {
    overflow-x: auto;
}

.results-table table {
    width: 100%;
    border-collapse: collapse;
    background: var(--glass-background);
    border-radius: var(--border-radius);
    overflow: hidden;
}

.results-table th,
.results-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid rgba(var(--primary-color-rgb), 0.1);
}

.results-table th {
    background: rgba(var(--primary-color-rgb), 0.1);
    font-weight: 600;
    color: var(--text-color);
}

.results-table td {
    color: var(--text-secondary);
}

.results-table tr.disabled {
    opacity: 0.5;
}

.status {
    padding: 4px 8px;
    border-radius: var(--border-radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
}

.status.ready {
    background: var(--success-color);
    color: white;
}

.status.running {
    background: var(--primary-color);
    color: white;
}

.status.coming-soon {
    background: rgba(var(--warning-color-rgb), 0.2);
    color: var(--warning-color);
}

.comparison-chart {
    text-align: center;
}

.comparison-chart h3 {
    margin-bottom: 15px;
    color: var(--text-color);
}

.chart-placeholder {
    background: var(--glass-background);
    border: var(--glass-border);
    border-radius: var(--border-radius);
    padding: 20px;
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#comparisonCanvas {
    max-width: 100%;
    height: auto;
}

.algorithm-explanation {
    display: grid;
    gap: 20px;
    margin-top: 20px;
}

.explanation-card {
    background: var(--glass-background);
    border: var(--glass-border);
    border-radius: var(--border-radius);
    padding: 25px;
    transition: all 0.3s ease;
}

.explanation-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.explanation-card.disabled {
    opacity: 0.6;
    filter: grayscale(30%);
}

.explanation-card h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.explanation-content {
    line-height: 1.6;
}

.explanation-content p {
    margin-bottom: 12px;
    color: var(--text-secondary);
}

.explanation-content strong {
    color: var(--text-color);
}

.complexity-analysis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-top: 20px;
    padding: 15px;
    background: rgba(var(--accent-color-rgb), 0.05);
    border-radius: var(--border-radius);
}

.complexity-item {
    text-align: center;
    padding: 10px;
    background: rgba(var(--accent-color-rgb), 0.1);
    border-radius: var(--border-radius-sm);
}

.complexity-item strong {
    display: block;
    color: var(--accent-color);
    margin-bottom: 5px;
    font-size: 0.9rem;
}

/* 动画效果 */
@keyframes levelUpPulse {
    0%, 100% { transform: translate(-50%, -50%) scale(1); }
    50% { transform: translate(-50%, -50%) scale(1.1); }
}

@keyframes achievementSlideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes achievementSlideOut {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* 响应式布局 - 新页面优化 */
.content-wrapper {
    display: flex;
    flex-direction: row;
    flex: 1;
    gap: var(--section-gap);
}

/* 教学页面响应式 */
@media (max-width: 768px) {
    .principle-explanation {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .unit-square {
        width: 150px;
        height: 150px;
    }
    
    .inscribed-circle {
        width: 150px;
        height: 150px;
    }
    
    .user-overview {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 15px;
    }
    
    .algorithm-grid {
        grid-template-columns: 1fr;
    }
    
    .comparison-results {
        grid-template-columns: 1fr;
    }
    
    .coming-soon-container {
        padding: 20px 15px;
    }
    
    .features-preview {
        padding: 15px;
    }
    
    .complexity-analysis {
        grid-template-columns: 1fr;
    }
    
    .user-stats-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .applications-grid {
        grid-template-columns: 1fr;
    }
    
    .comparison-controls {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }
}

@media (max-width: 480px) {
    .demo-canvas-container {
        text-align: center;
    }
    
    #tutorialCanvas {
        width: 100%;
        max-width: 300px;
        height: auto;
    }
    
    .control-row {
        flex-direction: column;
        align-items: stretch;
    }
    
    .control-row label {
        min-width: auto;
        margin-bottom: 5px;
    }
    
    .user-stats-grid {
        grid-template-columns: 1fr;
    }
    
    .algorithm-stats {
        gap: 8px;
    }
    
    .algorithm-stats span {
        padding: 6px 8px;
        font-size: 0.8rem;
    }
}

/* 三栏布局 */
.content-wrapper.three-column {
    display: grid;
    grid-template-columns: minmax(250px, 20%) minmax(300px, 40%) minmax(250px, 40%);
    gap: var(--main-content-gap, 24px);
    height: calc(100vh - 280px); /* 进一步调整高度以适应导航栏和页面头部 */
    min-height: 0;
    overflow: hidden;
    padding: 0 20px;
}

.content-wrapper.three-column > .sidebar,
.content-wrapper.three-column > .simulation-area,
.content-wrapper.three-column > .chart-area {
    height: 100%;
    max-height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.sidebar, .chart-area {
    overflow-y: auto;
}

/* 左侧边栏 */
.sidebar {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    border-radius: var(--border-radius);
    background: var(--current-background-color);
    box-shadow: none;
    transition: var(--transition);
    overflow-y: auto;
    height: 100%;
    max-height: calc(100vh - var(--header-height) - var(--footer-height) - (var(--section-gap) * 2) - 20px);
    padding-bottom: 20px;
    border: none;
}

.sidebar-content {
    padding: 0;
    flex-grow: 1;
}

/* 中间模拟区域 */
.simulation-area {
    display: flex;
    flex-direction: column;
    gap: var(--section-gap);
    height: 100%;
    overflow: hidden;
    min-height: 0;
}

.simulation-card {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: var(--glass-background);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: var(--shadow-lg);
    padding: 24px !important;
    height: 100%;
    border-radius: 20px !important;
    transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1) !important;
    position: relative;
    overflow: hidden;
}

.simulation-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--primary-gradient);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.simulation-card:hover::before {
    opacity: 1;
}

.simulation-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(var(--primary-color-rgb), 0.2);
}

.canvas-wrapper {
    flex: 1;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 450px !important;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    margin: 20px 0;
    border-radius: 16px;
    background:
        radial-gradient(circle at 30% 30%, rgba(var(--primary-color-rgb), 0.05) 0%, transparent 50%),
        radial-gradient(circle at 70% 70%, rgba(var(--accent-color-rgb), 0.03) 0%, transparent 50%),
        rgba(var(--primary-color-rgb), 0.02);
    border: 1px solid rgba(var(--primary-color-rgb), 0.1);
    box-shadow:
        var(--shadow-inner),
        0 0 20px rgba(var(--primary-color-rgb), 0.1);
    transition: all 0.3s ease;
}

.canvas-wrapper:hover {
    border-color: rgba(var(--primary-color-rgb), 0.2);
    box-shadow:
        var(--shadow-inner),
        0 0 30px rgba(var(--primary-color-rgb), 0.15);
}

.canvas-wrapper::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        45deg,
        transparent 0%,
        rgba(255, 255, 255, 0.02) 50%,
        transparent 100%
    );
    pointer-events: none;
    border-radius: 16px;
}

.canvas-container {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

canvas#simulationCanvas,
canvas#convergenceCanvas {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

/* 右侧图表区域 */
.chart-area {
    display: flex;
    flex-direction: column;
    gap: var(--section-gap);
    overflow-y: auto;
    max-height: calc(100vh - var(--header-height) - var(--footer-height) - (var(--section-gap) * 2) - 20px);
    background: var(--current-background-color);
    border-radius: var(--border-radius);
    box-shadow: none;
    padding: var(--card-padding);
    border: none;
}

.chart-card {
    background: var(--glass-background);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: var(--shadow-lg);
    padding: 24px !important;
    height: 100%;
    border-radius: 20px !important;
    transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1) !important;
}

.chart-container {
    width: 100%;
    height: 400px; /* 固定高度 */
    position: relative;
    border-radius: 16px;
    background: rgba(var(--primary-color-rgb), 0.02);
    border: 1px solid rgba(var(--primary-color-rgb), 0.05);
    box-shadow: var(--shadow-inner);
    overflow: hidden;
    margin-top: 16px;
}

.chart-container canvas {
    width: 100% !important;
    height: 100% !important;
    display: block;
}

/* 统计面板 */
.statistics-panel {
    padding: var(--card-padding);
    border-radius: var(--border-radius-sm);
    background: rgba(var(--primary-color-rgb), 0.03);
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: var(--section-gap);
    border: 1px solid rgba(var(--primary-color-rgb), 0.08);
    flex-shrink: 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
}

.stats-item {
    padding: 10px;
    border-radius: var(--border-radius-sm);
    text-align: center;
    background: transparent;
    border: 1px solid transparent;
    transition: var(--transition-fast);
}

.stats-item:hover {
    background: transparent;
    border-color: transparent;
    box-shadow: none;
}

.stats-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.stats-value {
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-accent);
}

/* 响应式调整 */
@media (max-width: 1600px) {
    :root {
        --sidebar-width-lg: 260px;
        --right-panel-width-lg: 300px;
        --card-padding: 16px;
    }
}

@media (max-width: 1400px) {
    .content-wrapper.three-column {
        grid-template-columns: minmax(220px, 22%) minmax(300px, 39%) minmax(250px, 39%);
    }
    
    h2 {
        font-size: 1.3rem;
    }
}

@media (max-width: 1200px) {
    .content-wrapper.three-column {
        grid-template-columns: minmax(200px, 25%) minmax(300px, 37.5%) minmax(250px, 37.5%);
    }
    
    .sidebar, .simulation-card, .chart-area {
        padding: 12px;
    }
    
    .card-header {
        padding-bottom: 10px;
    }
    
    .chart-area {
        gap: 15px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .sidebar .control-group h3 {
        font-size: 0.95rem;
    }
    
    .stats-label {
        font-size: 0.85rem;
    }
    
    .stats-value {
        font-size: 1.1rem;
    }
    
    .simulation-card {
        padding: 12px;
    }
    
    .chart-card {
        padding: 12px;
    }
}

@media (max-width: 991px) {
    .content-wrapper.three-column {
        display: flex;
        flex-direction: column;
        height: auto;
        overflow: visible;
    }
    
    .content-wrapper.three-column > .sidebar,
    .content-wrapper.three-column > .simulation-area,
    .content-wrapper.three-column > .chart-area {
        width: 100%;
        max-width: 100%;
        margin-bottom: var(--section-gap);
    }
    
    .simulation-area {
        min-height: 400px;
    }
    
    .canvas-wrapper {
        min-height: 300px;
    }
    
    .sidebar {
        max-height: none;
        overflow-y: visible;
    }
    
    .app-container {
        height: auto;
        overflow-y: auto;
    }
}

@media (max-width: 768px) {
    :root {
        --section-gap: 12px;
        --card-padding: 10px;
    }

    /* 移动端导航 */
    .nav-container {
        padding: 8px 16px;
        flex-wrap: wrap;
        gap: 12px;
    }

    .nav-menu {
        order: 3;
        width: 100%;
        justify-content: center;
        margin-top: 8px;
    }

    .nav-item {
        padding: 8px 12px;
        font-size: 0.9rem;
    }

    .nav-item span {
        display: none;
    }

    .nav-item i {
        font-size: 1.2rem;
    }

    .brand-text {
        font-size: 1rem;
    }

    /* 欢迎页面移动端 */
    .welcome-hero {
        min-height: 70vh;
        padding: 20px 10px;
    }

    .mega-pi-symbol {
        font-size: clamp(4rem, 12vw, 8rem);
    }

    .orbit-ring:nth-child(1) {
        width: 150px;
        height: 150px;
        margin: -75px 0 0 -75px;
    }

    .orbit-ring:nth-child(2) {
        width: 220px;
        height: 220px;
        margin: -110px 0 0 -110px;
    }

    .orbit-ring:nth-child(3) {
        width: 290px;
        height: 290px;
        margin: -145px 0 0 -145px;
    }

    .hero-actions {
        flex-direction: column;
        align-items: center;
    }

    .btn-hero {
        width: 100%;
        max-width: 280px;
        justify-content: center;
    }

    .feature-grid {
        grid-template-columns: 1fr;
        gap: 24px;
        padding: 0 10px;
    }

    .feature-card {
        padding: 30px 20px;
    }

    /* 页面头部移动端 */
    .page-header {
        flex-direction: column;
        gap: 16px;
        padding: 20px 16px;
        margin: 20px 10px 20px 10px; /* 增加顶部间距 */
        text-align: center;
    }

    .page-actions {
        width: 100%;
        justify-content: center;
    }

    /* 分析页面移动端 */
    .analysis-grid {
        grid-template-columns: 1fr;
        padding: 0 10px;
    }

    .analysis-card.stats-overview,
    .analysis-card.chart-multi {
        grid-column: span 1;
    }

    .stats-dashboard {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .stat-item {
        padding: 16px;
    }

    .chart-controls {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .table-container {
        font-size: 0.8rem;
    }

    .history-table th,
    .history-table td {
        padding: 8px 4px;
    }

    .app-container {
        padding-top: 140px; /* 进一步增加移动端导航栏高度 */
    }

    h1.gradient-text {
        font-size: 1.8rem;
    }

    h2 {
        font-size: 1.2rem;
    }
    
    .description {
        font-size: 0.9rem;
        margin-bottom: 10px;
    }
    
    .theme-toggle-container {
        margin-top: 10px;
    }
    
    .canvas-wrapper {
        min-height: 300px;
    }
    
    .simulation-card,
    .chart-card {
        padding: 10px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }
    
    .stats-item {
        padding: 8px;
    }
    
    .data-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .accuracy-meter {
        margin-top: 15px;
    }
    
    .accuracy-label, .accuracy-value {
        font-size: 0.85rem;
    }
    
    .footer-links, .social-links {
        flex-direction: column;
        gap: 8px;
    }
    
    .team-info {
        margin-left: 0;
        margin-top: 10px;
    }
}

/* 超小屏幕优化 */
@media (max-width: 576px) {
    :root {
        --section-gap: 10px;
        --card-padding: 8px;
        --border-radius: 8px;
        --border-radius-lg: 12px;
    }

    .app-container {
        padding: 10px;
        padding-top: 160px; /* 进一步增加移动端顶部间距 */
    }

    /* 导航栏超小屏优化 */
    .nav-container {
        padding: 6px 12px;
    }

    .nav-menu {
        gap: 4px;
    }

    .nav-item {
        padding: 6px 8px;
        min-width: 40px;
        justify-content: center;
    }

    .brand-text {
        font-size: 0.9rem;
    }

    /* 欢迎页面超小屏优化 */
    .welcome-hero {
        min-height: 60vh;
        padding: 15px 8px;
    }

    .hero-content {
        padding: 20px 10px;
    }

    .mega-pi-symbol {
        font-size: clamp(3rem, 10vw, 6rem);
    }

    .hero-title {
        font-size: clamp(1.8rem, 5vw, 2.5rem);
        margin-bottom: 15px;
    }

    .hero-description {
        font-size: clamp(0.9rem, 2vw, 1.1rem);
        margin-bottom: 30px;
    }

    .orbit-ring:nth-child(1) {
        width: 120px;
        height: 120px;
        margin: -60px 0 0 -60px;
    }

    .orbit-ring:nth-child(2) {
        width: 180px;
        height: 180px;
        margin: -90px 0 0 -90px;
    }

    .orbit-ring:nth-child(3) {
        width: 240px;
        height: 240px;
        margin: -120px 0 0 -120px;
    }

    .btn-hero {
        padding: 12px 24px;
        font-size: 1rem;
        width: 100%;
        max-width: 250px;
    }

    .welcome-features {
        padding: 40px 10px;
    }

    .feature-card {
        padding: 20px 15px;
    }

    .feature-icon {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
        margin-bottom: 15px;
    }

    .feature-card h3 {
        font-size: 1.2rem;
        margin-bottom: 10px;
    }

    .feature-card p {
        font-size: 0.9rem;
    }
    
    h1.gradient-text {
        font-size: 1.5rem;
    }
    
    h2 {
        font-size: 1.1rem;
    }
    
    .description {
        font-size: 0.85rem;
        margin-bottom: 8px;
    }
    
    .sidebar-content {
        padding: 8px;
    }
    
    .control-group {
        padding: 8px;
        margin-bottom: 10px;
    }
    
    .slider-container {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .slider-value {
        margin-bottom: 5px;
    }
    
    .btn {
        padding: 8px 12px;
        font-size: 0.9rem;
    }
    
    .legend-item {
        padding: 5px 10px;
        font-size: 0.85rem;
    }
    
    .canvas-wrapper {
        min-height: 250px;
    }
    
    .chart-container {
        min-height: 200px;
    }
    
    .chart-container {
        height: 250px;
    }
    
    .simulation-card {
        min-height: 300px;
    }
    
    .chart-card {
        min-height: 250px;
    }
    
    .data-grid {
        grid-template-columns: 1fr;
    }
    
    .data-item {
        padding: 8px;
    }
    
    .setting-item {
        flex-direction: column;
        align-items: flex-start;
        padding: 12px;
        gap: 10px;
    }
    
    .slider-container {
        max-width: 100%;
    }
    
    .setting-item span {
        margin-bottom: 5px;
    }
    
    .card-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .legend {
        margin-top: 8px;
        justify-content: flex-start;
    }
    
    .pi-value-overlay {
        font-size: 1.2rem;
        padding: 5px 10px;
    }
}

/* 横屏模式优化 */
@media (orientation: landscape) and (max-width: 991px) {
    .content-wrapper.three-column {
        grid-template-columns: minmax(200px, 300px) 1fr minmax(200px, 300px);
        grid-template-rows: auto;
        height: calc(100vh - var(--header-height) - var(--footer-height) - (var(--section-gap) * 2) - 20px);
        max-height: none;
        overflow: hidden;
    }
    
    .content-wrapper.three-column > .sidebar,
    .content-wrapper.three-column > .simulation-area,
    .content-wrapper.three-column > .chart-area {
        height: 100%;
        max-height: 100%;
        overflow: auto;
    }
    
    .simulation-area {
        min-height: 0;
    }
    
    .chart-area {
        min-height: 0;
    }
    
    .app-header {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }
    
    .logo-area {
        margin-bottom: 0;
    }
    
    .theme-toggle-container {
        margin-top: 0;
    }
}

/* 竖屏模式优化 */
@media (orientation: portrait) and (max-width: 991px) {
    .content-wrapper.three-column {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto auto;
        height: auto;
        max-height: none;
        overflow-y: auto;
    }
    
    .content-wrapper.three-column > .sidebar,
    .content-wrapper.three-column > .simulation-area,
    .content-wrapper.three-column > .chart-area {
        height: auto;
    }
    
    .simulation-area {
        min-height: 350px;
    }
    
    .chart-area {
        min-height: 350px;
    }
}

/* 小屏幕竖屏优化 */
@media (orientation: portrait) and (max-width: 576px) {
    .simulation-area {
        min-height: 300px;
    }
    
    .chart-area {
        min-height: 300px;
    }
    
    .data-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .app-header {
        padding: 12px;
    }
    
    .app-footer {
        padding: 10px;
        flex-direction: column;
        gap: 15px;
        padding: 15px;
    }
    
    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .social-links {
        margin-left: 0;
        padding-left: 0;
        border-left: none;
        margin-top: 10px;
    }
    
    .footer-badge {
        margin-top: 10px;
    }
}

/* 动画效果 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.5s ease-out forwards;
}

/* 自定义滚动条 */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

/* 无障碍焦点样式 */
:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

button:focus {
    outline: 2px solid white;
    outline-offset: -4px;
}

/* 按钮的活动状态 */
button.active {
    background: var(--glass-background);
    color: var(--primary-color);
    box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.1);
    transform: translateY(0);
}

#startBtn.active {
    background: linear-gradient(135deg, #059669, #047857);
    color: white;
}

#pauseBtn.active {
    background: linear-gradient(135deg, #d97706, #b45309);
    color: white;
}

#resetBtn.active {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    color: white;
}

/* 粒子效果 */
.particles-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
    z-index: 1;
}

.particle {
    position: absolute;
    width: 6px;
    height: 6px;
    background: var(--primary-light);
    border-radius: 50%;
    opacity: 0.6;
    pointer-events: none;
}

.particle:nth-child(1) {
    top: 20%;
    left: 20%;
    width: 8px;
    height: 8px;
    animation: floatingParticle 8s infinite ease-in-out;
}

.particle:nth-child(2) {
    top: 70%;
    left: 30%;
    width: 5px;
    height: 5px;
    animation: floatingParticle 12s infinite ease-in-out reverse;
}

.particle:nth-child(3) {
    top: 40%;
    left: 80%;
    width: 7px;
    height: 7px;
    animation: floatingParticle 9s infinite ease-in-out;
}

.particle:nth-child(4) {
    top: 80%;
    left: 70%;
    width: 4px;
    height: 4px;
    animation: floatingParticle 14s infinite ease-in-out reverse;
}

.particle:nth-child(5) {
    top: 10%;
    left: 50%;
    width: 6px;
    height: 6px;
    animation: floatingParticle 10s infinite ease-in-out;
}

.particle:nth-child(6) {
    top: 30%;
    left: 90%;
    width: 5px;
    height: 5px;
    animation: floatingParticle 11s infinite ease-in-out reverse;
}

.particle:nth-child(7) {
    top: 60%;
    left: 10%;
    width: 7px;
    height: 7px;
    animation: floatingParticle 13s infinite ease-in-out;
}

.particle:nth-child(8) {
    top: 90%;
    left: 40%;
    width: 6px;
    height: 6px;
    animation: floatingParticle 15s infinite ease-in-out reverse;
}

@keyframes floatingParticle {
    0% {
        transform: translate(0, 0) scale(1);
        opacity: 0.6;
    }
    25% {
        transform: translate(30px, 15px) scale(1.2);
        opacity: 0.8;
    }
    50% {
        transform: translate(10px, 40px) scale(1);
        opacity: 0.6;
    }
    75% {
        transform: translate(-20px, 20px) scale(1.1);
        opacity: 0.7;
    }
    100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.6;
    }
}

/* 图表覆盖层样式 */
.chart-container {
    position: relative;
}

.chart-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 2;
}

.real-pi-line {
    position: absolute;
    width: 100%;
    height: 2px;
    background: linear-gradient(to right, transparent, var(--accent-color), transparent);
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.6;
    box-shadow: 0 0 8px var(--accent-color);
}

.real-pi-label {
    position: absolute;
    right: 10px;
    top: 10px;
    padding: 4px 8px;
    background: var(--glass-background);
    color: var(--accent-color);
    border-radius: var(--border-radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    box-shadow: var(--shadow-sm);
    border: var(--glass-border);
}

/* 改进的画布覆盖层 */
.canvas-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    z-index: 3;
}

.pi-value-overlay {
    background: var(--glass-background);
    padding: 10px 20px;
    border-radius: var(--border-radius);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    box-shadow: var(--shadow);
    border: var(--glass-border);
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-color);
    opacity: 0.9;
    transition: var(--transition);
}

#piValueOverlay {
    color: var(--accent-color);
    font-size: 1.8rem;
    font-weight: 800;
    text-shadow: 0 0 5px rgba(var(--accent-color-rgb), 0.3);
}

/* 改进的按钮样式 */
.btn {
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(255,255,255,0.2), rgba(255,255,255,0));
    opacity: 0;
    transition: var(--transition);
}

.btn:hover::after {
    opacity: 1;
}

/* 添加脉冲动画到主要按钮 */
@keyframes softPulse {
    0%, 100% {
        box-shadow: 0 0 0 rgba(var(--primary-color-rgb), 0);
    }
    50% {
        box-shadow: 0 0 15px rgba(var(--primary-color-rgb), 0.5);
    }
}

/* 精确度条样式 */
.accuracy-meter {
    margin-top: 20px;
    background: var(--glass-background);
    border-radius: var(--border-radius);
    padding: 15px;
    border: var(--glass-border);
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.accuracy-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.accuracy-bar-container {
    height: 8px;
    background: rgba(var(--primary-color-rgb), 0.1);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

.accuracy-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(to right, var(--primary-light), var(--accent-color));
    border-radius: 10px;
    transition: width 0.8s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
    overflow: hidden;
}

.accuracy-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.4) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    animation: shimmer 2s infinite;
}

.accuracy-value {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--accent-color);
    margin-left: 8px;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* 数据网格改进 */
.data-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-top: 15px;
}

.data-item {
    padding: 15px;
    border-radius: var(--border-radius);
    background: var(--glass-background);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border: var(--glass-border);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.data-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.data-card {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 20px;
    border-radius: var(--border-radius);
    background: var(--glass-background);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: var(--glass-border);
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.data-card i {
    font-size: 2.5rem;
    color: var(--accent-color);
}

.data-card .data-value {
    font-size: 2.2rem;
    font-weight: 800;
    background: linear-gradient(to right, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    transition: all 0.3s ease;
}

.data-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg), 0 0 20px rgba(var(--accent-color-rgb), 0.3);
}

.data-card:hover .data-value {
    transform: scale(1.05);
}

.data-card:hover i {
    animation: spinIcon 1.5s ease-in-out;
}

@keyframes spinIcon {
    0% { transform: rotate(0deg); }
    25% { transform: rotate(90deg); }
    50% { transform: rotate(180deg); }
    75% { transform: rotate(270deg); }
    100% { transform: rotate(360deg); }
}

/* 统一开关容器样式 */
.switch-container {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 修复开关大小和对齐问题 */
.setting-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    background: rgba(var(--primary-color-rgb), 0.05);
    border-radius: var(--border-radius);
    margin-bottom: 15px;
    border: 1px solid rgba(var(--primary-color-rgb), 0.1);
    transition: all 0.3s ease;
    width: 100%;
    min-height: 50px;
}

.setting-item:hover {
    background: rgba(var(--primary-color-rgb), 0.08);
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

.setting-item span {
    font-weight: 500;
    font-size: 1.05rem;
    flex: 1;
}

/* 开关按钮样式优化 */
.switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    vertical-align: middle;
    margin-left: auto;
    cursor: pointer;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.switch-slider {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(var(--text-tertiary-rgb, 148, 163, 184), 0.4);
    transition: .4s cubic-bezier(0.22, 1, 0.36, 1);
    border-radius: 24px;
}

.switch-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .4s cubic-bezier(0.22, 1, 0.36, 1);
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

input:checked + .switch-slider {
    background-color: var(--primary-color);
}

input:checked + .switch-slider:before {
    transform: translateX(20px);
}

input:focus + .switch-slider {
    box-shadow: 0 0 1px var(--primary-color);
}

/* 开关悬停效果 */
.switch:hover .switch-slider:before {
    box-shadow: 0 0 8px rgba(var(--primary-color-rgb), 0.5);
}

.switch-slider:after {
    content: '';
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: -4px;
    background: radial-gradient(circle at center, rgba(var(--primary-color-rgb), 0.2) 0%, rgba(var(--primary-color-rgb), 0) 70%);
    border-radius: 28px;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

input:checked + .switch-slider:after {
    opacity: 1;
}

/* 确保设置项垂直居中对齐 */
.settings-content .setting-item {
    min-height: 50px;
}

/* 确保滑块容器垂直居中 */
.slider-container {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    width: 100%;
    max-width: 60%;
    gap: 10px;
    position: relative;
    min-height: 24px;
}

.slider-labels {
    display: flex;
    justify-content: space-between;
    width: 100%;
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 4px;
}

/* 卡片样式优化 */
.card {
    background: var(--card-background);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow);
    padding: 20px;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
    overflow: hidden;
    height: 100%;
}

.card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-3px);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid transparent;
    background: linear-gradient(90deg,
        rgba(var(--primary-color-rgb), 0.1) 0%,
        rgba(var(--accent-color-rgb), 0.05) 50%,
        rgba(var(--secondary-color-rgb), 0.1) 100%) bottom;
    background-size: 100% 2px;
    background-repeat: no-repeat;
    position: relative;
}

.card-header::before {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-gradient);
    transition: width 0.3s ease;
}

.analysis-card:hover .card-header::before {
    width: 100%;
}

h2 {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

h2 i {
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-size: 1.2rem;
}

/* 侧边栏 */
.sidebar-nav {
    display: flex;
    flex-direction: column;
    background: rgba(var(--primary-color-rgb), 0.05);
    border-bottom: 1px solid rgba(128, 128, 128, 0.1);
    gap: 4px;
    padding: 12px 8px;
}

.nav-tab {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: var(--border-radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition-fast);
    border-left: 3px solid transparent;
}

.nav-tab:hover {
    background: rgba(var(--primary-color-rgb), 0.1);
    color: var(--primary-color);
}

.nav-tab.active {
    background: rgba(var(--primary-color-rgb), 0.15);
    color: var(--primary-color);
    border-left: 3px solid var(--primary-color);
    font-weight: 600;
}

.nav-tab i {
    font-size: 1.2rem;
}

.sidebar-section {
    display: none;
    animation: fadeIn 0.5s ease;
}

.sidebar-section.active {
    display: block;
}

/* 控制面板 */
.control-panel {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.control-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(var(--primary-color-rgb), 0.1);
}

.control-group:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.btn-group {
    display: flex;
    gap: 10px;
}

h3 {
    font-weight: 600;
    font-size: 1rem;
    color: var(--text-color);
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
}

h3 i {
    color: var(--primary-color);
    font-size: 1.2rem;
}

/* 按钮样式 */
.btn {
    background: var(--glass-background);
    color: var(--text-color);
    border: none;
    padding: 10px 16px;
    border-radius: var(--border-radius-sm);
    cursor: pointer;
    transition: var(--transition);
    font-weight: 600;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: var(--shadow-sm);
    flex: 1;
    position: relative;
    overflow: hidden;
}

.btn i {
    font-size: 1.1rem;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

.btn:active {
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
}

.btn.small {
    padding: 6px 12px;
    font-size: 0.85rem;
}

.btn.small i {
    font-size: 0.95rem;
}

.btn.primary {
    background: var(--primary-gradient);
    color: white;
    animation: softPulse 2s infinite ease-in-out;
}

.btn.secondary {
    background: var(--secondary-gradient);
    color: white;
}

.btn.warning {
    background: linear-gradient(135deg, var(--warning-color), #d97706);
    color: white;
}

.btn.danger {
    background: linear-gradient(135deg, var(--danger-color), #dc2626);
    color: white;
}

.btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(255,255,255,0.2), rgba(255,255,255,0));
    opacity: 0;
    transition: var(--transition);
}

.btn:hover::after {
    opacity: 1;
}

/* 表单元素 */
.control-item {
    background: rgba(var(--primary-color-rgb), 0.03);
    border-radius: var(--border-radius-sm);
    padding: 16px;
    border: 1px solid rgba(var(--primary-color-rgb), 0.08);
    transition: var(--transition);
}

.control-item:hover {
    background: rgba(var(--primary-color-rgb), 0.05);
    border-color: rgba(var(--primary-color-rgb), 0.12);
}

/* 数据统计区 */
.data-summary {
    margin-top: 20px;
}

.data-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    background: var(--glass-background);
    border-radius: var(--border-radius);
    transition: var(--transition);
    border: var(--glass-border);
    margin-bottom: 20px;
}

.data-card i {
    font-size: 2rem;
    color: var(--accent-color);
}

.data-card .data-value {
    font-size: 2rem;
    font-weight: 700;
    background: linear-gradient(to right, var(--accent-color), var(--primary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.data-card .data-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-top: 5px;
}

.data-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.data-item {
    display: flex;
    flex-direction: column;
    padding: 16px;
    background: var(--glass-background);
    border-radius: var(--border-radius);
    transition: var(--transition);
    border: var(--glass-border);
    text-align: center;
}

.data-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow);
}

.data-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-top: 6px;
}

.data-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-accent);
    transition: var(--transition);
}

.data-value.changing {
    animation: pulse 0.5s cubic-bezier(0.4, 0, 0.6, 1);
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); opacity: 0.9; }
}

.highlight {
    position: relative;
}

.highlight::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: var(--border-radius);
    z-index: -1;
    background: linear-gradient(135deg, rgba(var(--primary-color-rgb), 0.1), rgba(var(--accent-color-rgb), 0.1));
    opacity: 0.7;
    transition: var(--transition);
}

.highlight:hover::before {
    opacity: 1;
}

/* 图表区域 */
.chart-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(255,255,255,0.05), transparent);
    pointer-events: none;
}

/* 图例 */
.legend {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 15px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
    background: var(--glass-background);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    padding: 8px 16px;
    border-radius: 20px;
    border: var(--glass-border);
}

.legend-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

.legend-color {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.inside {
    background-color: var(--point-inside-color);
}

.outside {
    background-color: var(--point-outside-color);
}

/* 页脚样式改进 */
.app-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 30px;
    margin-top: 20px;
    position: relative;
    overflow: hidden;
}

.pi-real-value {
    display: flex;
    align-items: center;
    gap: 5px;
}

.pi-digits {
    font-family: 'Courier New', monospace;
    font-weight: 600;
    color: var(--accent-color);
    position: relative;
    overflow: hidden;
    display: inline-block;
}

.pi-digits::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 20px;
    height: 100%;
    background: linear-gradient(to right, transparent, var(--glass-background));
}

.footer-links {
    display: flex;
    align-items: center;
    gap: 15px;
    position: relative;
}

.footer-link {
    display: flex;
    align-items: center;
    gap: 5px;
    color: var(--text-color);
    text-decoration: none;
    font-size: 0.9rem;
    transition: var(--transition);
    padding: 5px 10px;
    border-radius: var(--border-radius-sm);
}

.footer-link:hover {
    background: rgba(var(--primary-color-rgb), 0.1);
    transform: translateY(-2px);
    color: var(--primary-color);
}

.social-links {
    display: flex;
    gap: 10px;
    margin-left: 10px;
    padding-left: 10px;
    border-left: 1px solid rgba(128, 128, 128, 0.2);
}

.social-link {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-color);
    background: rgba(255, 255, 255, 0.1);
    transition: var(--transition);
    position: relative;
}

.social-link:hover {
    transform: translateY(-3px) scale(1.1);
    color: white;
    background: var(--primary-gradient);
    box-shadow: 0 5px 15px rgba(var(--primary-color-rgb), 0.3);
}

.social-link i {
    font-size: 1.2rem;
}

.footer-badge {
    position: relative;
}

.badge {
    background: var(--primary-gradient);
    color: white;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    position: relative;
    cursor: pointer;
}

.badge-tooltip {
    position: absolute;
    bottom: 100%;
    right: 0;
    background: var(--glass-background);
    border: var(--glass-border);
    padding: 5px 10px;
    border-radius: var(--border-radius-sm);
    font-size: 0.8rem;
    white-space: nowrap;
    box-shadow: var(--shadow);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    opacity: 0;
    transform: translateY(10px);
    pointer-events: none;
    transition: var(--transition);
}

.badge:hover + .badge-tooltip {
    opacity: 1;
    transform: translateY(0);
}

.slider-value {
    min-width: 30px;
    text-align: center;
    font-weight: 600;
    color: var(--primary-color);
    background: rgba(var(--primary-color-rgb), 0.1);
    border-radius: 4px;
    padding: 2px 8px;
    transition: all 0.3s ease;
}

/* 确保主题切换开关样式一致 */
.theme-toggle-container .switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
    margin: 0 5px;
}

/* 滑动条的样式优化 */
input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 6px;
    background: linear-gradient(to right, var(--primary-color) 0%, var(--primary-color) 50%, #e2e8f0 50%, #e2e8f0 100%);
    border-radius: 10px;
    outline: none;
    margin: 10px 0;
    transition: var(--transition);
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.15);
    transition: all 0.2s ease-in-out;
}

input[type="range"]::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.15);
    transition: all 0.2s ease-in-out;
    border: none;
}

input[type="range"]::-webkit-slider-thumb:hover,
input[type="range"]::-moz-range-thumb:hover {
    transform: scale(1.2);
    box-shadow: 0 2px 8px rgba(var(--primary-color-rgb), 0.4);
}

input[type="range"]:focus {
    outline: none;
}

/* 设置滑块轨道背景色随值变化 */
input[type="range"].color-track {
    background: linear-gradient(to right, var(--primary-color) 0%, var(--primary-color) var(--range-progress, 50%), #e2e8f0 var(--range-progress, 50%), #e2e8f0 100%);
}

/* 深色模式下的滑动条样式 */
html[data-theme='dark'] input[type="range"] {
    background: linear-gradient(to right, var(--primary-color) 0%, var(--primary-color) 50%, #2d3748 50%, #2d3748 100%);
}

html[data-theme='dark'] input[type="range"].color-track {
    background: linear-gradient(to right, var(--primary-color) 0%, var(--primary-color) var(--range-progress, 50%), #2d3748 var(--range-progress, 50%), #2d3748 100%);
}

/* 大屏幕优化 */
@media (min-width: 1400px) {
    .nav-container {
        max-width: 1600px;
    }

    .welcome-hero {
        min-height: 85vh;
    }

    .mega-pi-symbol {
        font-size: clamp(8rem, 12vw, 14rem);
    }

    .hero-title {
        font-size: clamp(3rem, 5vw, 4.5rem);
    }

    .feature-grid {
        max-width: 1400px;
        grid-template-columns: repeat(3, 1fr);
        gap: 50px;
    }

    .analysis-grid {
        max-width: 1600px;
        grid-template-columns: repeat(3, 1fr);
    }

    .analysis-card.stats-overview {
        grid-column: span 3;
    }

    .analysis-card.chart-multi {
        grid-column: span 2;
    }
}

/* 中等屏幕优化 */
@media (min-width: 992px) and (max-width: 1199px) {
    .content-wrapper.three-column {
        grid-template-columns: minmax(200px, 22%) minmax(300px, 39%) minmax(250px, 39%);
        gap: 20px;
    }

    .analysis-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .analysis-card.stats-overview,
    .analysis-card.chart-multi {
        grid-column: span 2;
    }
}

/* 平板横屏优化 */
@media (min-width: 768px) and (max-width: 991px) and (orientation: landscape) {
    .welcome-hero {
        min-height: 75vh;
    }

    .hero-actions {
        flex-direction: row;
        gap: 20px;
    }

    .btn-hero {
        width: auto;
        min-width: 200px;
    }

    .feature-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
}

/* 平板竖屏优化 */
@media (min-width: 768px) and (max-width: 991px) and (orientation: portrait) {
    .welcome-hero {
        min-height: 70vh;
    }

    .feature-grid {
        grid-template-columns: 1fr;
        gap: 25px;
        max-width: 500px;
    }

    .analysis-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

/* 触摸设备优化 */
@media (hover: none) and (pointer: coarse) {
    .btn, .nav-item, .feature-card {
        min-height: 44px; /* 确保触摸目标足够大 */
    }

    .nav-item {
        padding: 12px 16px;
    }

    .btn-hero {
        min-height: 50px;
        padding: 16px 32px;
    }

    /* 移除悬停效果，因为触摸设备不支持 */
    .btn:hover,
    .nav-item:hover,
    .feature-card:hover,
    .analysis-card:hover {
        transform: none;
    }

    /* 添加触摸反馈 */
    .btn:active,
    .nav-item:active {
        transform: scale(0.95);
        transition: transform 0.1s ease;
    }
}

/* 高分辨率屏幕优化 */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .logo-icon,
    .mega-pi-symbol,
    .feature-icon {
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }
}

/* 减少动画偏好 */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }

    .mega-pi-symbol,
    .orbit-ring,
    .particle,
    .particle-enhanced {
        animation: none !important;
    }
}

/* 打印样式 */
@media print {
    .global-nav,
    .nav-controls,
    .hero-actions,
    .page-actions,
    .particles-bg,
    .particle,
    .particle-enhanced,
    .data-stream {
        display: none !important;
    }

    .page-container {
        display: block !important;
        opacity: 1 !important;
        transform: none !important;
    }

    .welcome-hero {
        min-height: auto;
        padding: 20px;
    }

    .analysis-grid {
        grid-template-columns: 1fr !important;
    }

    .content-wrapper.three-column {
        display: block !important;
        height: auto !important;
    }

    .sidebar,
    .simulation-area,
    .chart-area {
        width: 100% !important;
        margin-bottom: 20px;
    }
}

/* 错误提示动画 */
@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* 调试模式样式 */
.debug-mode {
    position: relative;
}

.debug-mode::before {
    content: 'DEBUG MODE';
    position: fixed;
    top: 10px;
    left: 10px;
    background: #ff6b6b;
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: bold;
    z-index: 10001;
}

/* 加载状态样式 */
.loading {
    position: relative;
    overflow: hidden;
}

.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(var(--primary-color-rgb), 0.2),
        transparent
    );
    animation: loading-shimmer 1.5s infinite;
}

@keyframes loading-shimmer {
    0% {
        left: -100%;
    }
    100% {
        left: 100%;
    }
}

/* 无障碍增强 */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* 焦点指示器增强 */
.focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: 2px;
    border-radius: var(--border-radius-sm);
}

/* 高对比度模式支持 */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #0000ff;
        --accent-color: #ff0000;
        --text-color: #000000;
        --background-color: #ffffff;
        --glass-background: rgba(255, 255, 255, 0.95);
        --glass-border: 2px solid #000000;
    }

    .btn, .nav-item {
        border: 2px solid currentColor;
    }
}

/* 暗色主题高对比度 */
@media (prefers-contrast: high) and (prefers-color-scheme: dark) {
    :root {
        --primary-color: #00ffff;
        --accent-color: #ffff00;
        --text-color: #ffffff;
        --background-color: #000000;
        --glass-background: rgba(0, 0, 0, 0.95);
        --glass-border: 2px solid #ffffff;
    }
}

/* ========================================
   国家级设计优化样式 - 新增样式
   ======================================== */

/* 专业启动屏幕样式 */
.championship-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    opacity: 1;
    transition: opacity 0.5s ease;
}

.championship-loader.hidden {
    opacity: 0;
    pointer-events: none;
}

.loader-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.mathematical-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(255,255,255,0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.1) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: gridMove 20s linear infinite;
}

@keyframes gridMove {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

.floating-equations {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.equation {
    position: absolute;
    color: rgba(255, 255, 255, 0.3);
    font-size: 14px;
    font-family: 'KaTeX_Math', serif;
    animation: floatEquation 15s linear infinite;
}

.equation:nth-child(1) {
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.equation:nth-child(2) {
    top: 60%;
    right: 15%;
    animation-delay: 5s;
}

.equation:nth-child(3) {
    bottom: 30%;
    left: 20%;
    animation-delay: 10s;
}

@keyframes floatEquation {
    0% { opacity: 0; transform: translateY(50px); }
    20% { opacity: 1; transform: translateY(0); }
    80% { opacity: 1; transform: translateY(-20px); }
    100% { opacity: 0; transform: translateY(-50px); }
}

.loader-content {
    position: relative;
    text-align: center;
    z-index: 2;
}

.championship-logo {
    position: relative;
    margin-bottom: 40px;
}

.logo-animation {
    position: relative;
    width: 120px;
    height: 120px;
    margin: 0 auto;
}

.pi-ring {
    position: absolute;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    animation: ringRotate 3s linear infinite;
}

.pi-ring.outer {
    width: 120px;
    height: 120px;
    top: 0;
    left: 0;
    animation-direction: normal;
}

.pi-ring.middle {
    width: 80px;
    height: 80px;
    top: 20px;
    left: 20px;
    animation-direction: reverse;
    animation-duration: 2s;
}

.pi-ring.inner {
    width: 40px;
    height: 40px;
    top: 40px;
    left: 40px;
    animation-duration: 1.5s;
}

@keyframes ringRotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.pi-symbol-loader {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 48px;
    font-weight: bold;
    color: white;
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
    animation: symbolPulse 2s ease-in-out infinite;
}

@keyframes symbolPulse {
    0%, 100% { transform: translate(-50%, -50%) scale(1); }
    50% { transform: translate(-50%, -50%) scale(1.1); }
}

.logo-particles {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: white;
    border-radius: 50%;
    animation: particleFloat 4s ease-in-out infinite;
}

.particle:nth-child(1) { animation-delay: 0s; top: -60px; left: 0; }
.particle:nth-child(2) { animation-delay: 0.8s; top: -30px; left: 50px; }
.particle:nth-child(3) { animation-delay: 1.6s; top: 30px; left: 40px; }
.particle:nth-child(4) { animation-delay: 2.4s; top: 40px; left: -40px; }
.particle:nth-child(5) { animation-delay: 3.2s; top: -40px; left: -30px; }

@keyframes particleFloat {
    0%, 100% { opacity: 0; transform: translateY(0); }
    50% { opacity: 1; transform: translateY(-20px); }
}

.title-with-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-bottom: 10px;
}

.title-icon {
    font-size: 3rem;
    color: var(--primary-color);
    filter: drop-shadow(0 0 15px rgba(var(--primary-color-rgb), 0.6));
    animation: iconPulse 3s ease-in-out infinite;
}

@keyframes iconPulse {
    0%, 100% { 
        transform: scale(1);
        filter: drop-shadow(0 0 15px rgba(var(--primary-color-rgb), 0.6));
    }
    50% { 
        transform: scale(1.1);
        filter: drop-shadow(0 0 25px rgba(var(--primary-color-rgb), 0.8));
    }
}

.title-text {
    text-align: left;
}

.championship-title h1 {
    font-size: 32px;
    font-weight: 700;
    color: white;
    margin-bottom: 10px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.championship-subtitle {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 40px;
}

.loading-system {
    max-width: 400px;
    margin: 0 auto;
}

.loading-progress {
    margin-bottom: 30px;
}

.progress-bar-championship {
    position: relative;
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill-championship {
    height: 100%;
    background: linear-gradient(90deg, #00d4ff, #0099cc);
    border-radius: 4px;
    transition: width 0.3s ease;
    position: relative;
}

.progress-glow {
    position: absolute;
    top: -2px;
    right: -10px;
    width: 20px;
    height: 12px;
    background: radial-gradient(ellipse, rgba(0, 212, 255, 0.8), transparent);
    border-radius: 50%;
    animation: progressGlow 1s ease-in-out infinite alternate;
}

@keyframes progressGlow {
    0% { opacity: 0.5; }
    100% { opacity: 1; }
}

.progress-percentage {
    color: white;
    font-size: 18px;
    font-weight: 600;
}

.loading-stages {
    text-align: left;
    margin-bottom: 30px;
}

.stage-item {
    display: flex;
    align-items: center;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 12px;
    transition: color 0.3s ease;
}

.stage-item.active {
    color: white;
}

.stage-item.completed {
    color: #00ff88;
}

.stage-item i {
    margin-right: 12px;
    width: 20px;
}

.stage-check {
    margin-left: auto;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.stage-item.completed .stage-check {
    opacity: 1;
    color: #00ff88;
}

.system-info {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.info-item {
    color: rgba(255, 255, 255, 0.7);
    font-size: 12px;
}

.info-label {
    opacity: 0.8;
}

.info-value {
    color: white;
    font-weight: 600;
}

/* 性能监控面板样式 */
.performance-monitor-panel {
    position: fixed;
    top: 100px;
    right: -320px;
    width: 320px;
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-lg);
    z-index: 9000;
    transition: right 0.3s ease;
}

.performance-monitor-panel.open {
    right: 20px;
}

.monitor-toggle {
    position: absolute;
    left: -50px;
    top: 20px;
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    border-radius: var(--border-radius-md) 0 0 var(--border-radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: white;
    font-size: 20px;
    transition: background 0.3s ease;
}

.monitor-toggle:hover {
    background: var(--primary-color-hover);
}

.monitor-content {
    padding: 20px;
}

.monitor-header {
    display: flex;
    justify-content: between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.monitor-header h3 {
    margin: 0;
    color: var(--text-color);
    font-size: 18px;
}

.monitor-controls {
    display: flex;
    gap: 8px;
}

.monitor-btn {
    padding: 4px 8px;
    background: var(--accent-color);
    color: white;
    border: none;
    border-radius: var(--border-radius-sm);
    font-size: 12px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.monitor-btn:hover {
    background: var(--accent-color-hover);
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-bottom: 20px;
}

.metric-card {
    background: rgba(255, 255, 255, 0.05);
    padding: 12px;
    border-radius: var(--border-radius-md);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.metric-icon {
    font-size: 16px;
    margin-bottom: 8px;
}

.metric-info {
    margin-bottom: 8px;
}

.metric-label {
    display: block;
    font-size: 11px;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.metric-value {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-color);
}

.metric-chart {
    height: 30px;
}

.advanced-metrics {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 15px;
}

.advanced-metric {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

.metric-name {
    font-size: 12px;
    color: var(--text-secondary);
    width: 80px;
}

.efficiency-bar {
    flex: 1;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    margin: 0 10px;
    overflow: hidden;
}

.efficiency-fill {
    height: 100%;
    background: linear-gradient(90deg, #ff6b6b, #ffd93d, #6bcf7f);
    border-radius: 3px;
}

.precision-indicator {
    display: flex;
    gap: 4px;
    margin: 0 10px;
}

.precision-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
}

.precision-dot.active {
    background: var(--primary-color);
}

.metric-rating {
    font-size: 12px;
    font-weight: 600;
    color: var(--accent-color);
    min-width: 40px;
    text-align: right;
}

/* 教学系统重设计样式 */
.tutorial-redesigned {
    padding: 0;
}

.learning-section {
    margin-bottom: 40px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding: 0 var(--section-padding);
}

.section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 24px;
    font-weight: 700;
    color: var(--text-color);
    margin: 0;
}

.icon-wrapper {
    font-size: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.difficulty-badge {
    padding: 6px 12px;
    border-radius: var(--border-radius-full);
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.difficulty-badge.expert {
    background: linear-gradient(135deg, #ff6b6b, #ee5a52);
    color: white;
}

.concept-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 25px;
    padding: 0 var(--section-padding);
}

.concept-card {
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-xl);
    padding: 25px;
    box-shadow: var(--shadow-lg);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.concept-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
}

.concept-card.mathematical::before {
    background: linear-gradient(90deg, #667eea, #764ba2);
}

.concept-card.statistical::before {
    background: linear-gradient(90deg, #f093fb, #f5576c);
}

.concept-card.complexity::before {
    background: linear-gradient(90deg, #4facfe, #00f2fe);
}

.concept-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.card-icon {
    font-size: 32px;
    margin-right: 15px;
}

.card-header h3 {
    flex: 1;
    margin: 0;
    font-size: 20px;
    font-weight: 600;
}

.card-status {
    padding: 4px 8px;
    background: var(--accent-color);
    color: white;
    border-radius: var(--border-radius-sm);
    font-size: 11px;
    font-weight: 500;
}

/* 高级页脚样式 */
.app-footer-premium {
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-xl) var(--border-radius-xl) 0 0;
    margin-top: 60px;
    padding: 40px var(--section-padding);
    position: relative;
    overflow: hidden;
}

.app-footer-premium::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, 
        transparent, 
        var(--primary-color), 
        var(--accent-color), 
        transparent
    );
}

.mathematical-constants {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.constant-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.constant-item.featured {
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.constant-symbol {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-color);
}

.constant-item.featured .constant-symbol {
    font-size: 36px;
    margin-bottom: 8px;
}

.constant-digits {
    position: relative;
}

.constant-label {
    font-size: 12px;
    color: var(--text-secondary);
    display: block;
    margin-bottom: 4px;
}

.pi-digits-animated {
    font-family: 'Courier New', monospace;
    font-size: 14px;
    color: var(--text-color);
    position: relative;
}

.digits-glow {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(var(--primary-color-rgb), 0.3), 
        transparent
    );
    animation: digitsGlow 3s ease-in-out infinite;
}

@keyframes digitsGlow {
    0%, 100% { opacity: 0; }
    50% { opacity: 1; }
}

.constant-value {
    font-family: 'Courier New', monospace;
    font-size: 14px;
    color: var(--text-secondary);
}

.project-info-premium {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 20px;
}

.project-badge {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 20px;
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    color: #333;
    border-radius: var(--border-radius-lg);
    box-shadow: 0 8px 25px rgba(255, 215, 0, 0.3);
}

.project-badge.championship {
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    animation: championshipGlow 2s ease-in-out infinite alternate;
}

@keyframes championshipGlow {
    0% { box-shadow: 0 8px 25px rgba(255, 215, 0, 0.3); }
    100% { box-shadow: 0 12px 35px rgba(255, 215, 0, 0.5); }
}

.badge-icon {
    font-size: 24px;
}

.badge-content {
    display: flex;
    flex-direction: column;
}

.badge-title {
    font-weight: 700;
    font-size: 14px;
}

.badge-version {
    font-size: 12px;
    opacity: 0.8;
}

.technical-specs {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.spec-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
}

.spec-label {
    color: var(--text-secondary);
}

.spec-value {
    color: var(--text-color);
    font-weight: 600;
}

.honors-showcase {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.honor-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: var(--border-radius-md);
    font-size: 12px;
    font-weight: 500;
}

.honor-item.gold {
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    color: #333;
}

.honor-item.silver {
    background: linear-gradient(135deg, #c0c0c0, #e8e8e8);
    color: #333;
}

.honor-item.bronze {
    background: linear-gradient(135deg, #cd7f32, #daa520);
    color: white;
}

.system-status {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text-secondary);
}

.status-indicator.online {
    color: #00ff88;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: currentColor;
    animation: statusPulse 2s ease-in-out infinite;
}

@keyframes statusPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.uptime {
    font-size: 12px;
    color: var(--text-secondary);
}

/* 响应式优化 */
@media (max-width: 768px) {
    .championship-title h1 {
        font-size: 24px;
    }
    
    .loading-stages {
        font-size: 14px;
    }
    
    .performance-monitor-panel {
        width: 280px;
        right: -280px;
    }
    
    .performance-monitor-panel.open {
        right: 10px;
    }
    
    .metrics-grid {
        grid-template-columns: 1fr;
    }
    
    .concept-cards-grid {
        grid-template-columns: 1fr;
        padding: 0 15px;
    }
    
    .mathematical-constants {
        flex-direction: column;
        align-items: center;
    }
    
    .project-info-premium {
        flex-direction: column;
        text-align: center;
    }
    
    .honors-showcase {
        flex-direction: column;
        align-items: center;
    }
    
    .system-status {
        flex-direction: column;
    }
}

/* 算法对比页面重设计样式 */
.comparison-redesigned {
    padding: 0;
}

.comparison-header-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.floating-algorithm-icon {
    font-size: 48px;
    margin-bottom: 20px;
    animation: floatIcon 3s ease-in-out infinite;
}

@keyframes floatIcon {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.performance-dashboard {
    display: flex;
    gap: 30px;
    margin-top: 20px;
    flex-wrap: wrap;
    justify-content: center;
}

.dashboard-metric {
    text-align: center;
}

.metric-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-color);
    display: block;
}

.metric-label {
    font-size: 12px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.algorithms-showcase {
    margin-bottom: 40px;
}

.selection-controls {
    display: flex;
    gap: 10px;
}

.selection-btn {
    padding: 8px 16px;
    background: var(--accent-color);
    color: white;
    border: none;
    border-radius: var(--border-radius-md);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.selection-btn:hover {
    background: var(--accent-color-hover);
    transform: translateY(-2px);
}

.algorithms-grid-enhanced {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    padding: 0 var(--section-padding);
}

.algorithm-card-enhanced {
    position: relative;
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-xl);
    padding: 25px;
    box-shadow: var(--shadow-lg);
    transition: all 0.3s ease;
    overflow: hidden;
    cursor: pointer;
}

.algorithm-card-enhanced::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(var(--primary-color-rgb), 0.1), rgba(var(--accent-color-rgb), 0.1));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.algorithm-card-enhanced:hover::before {
    opacity: 1;
}

.algorithm-card-enhanced.selected {
    border-color: var(--primary-color);
    box-shadow: 0 0 30px rgba(var(--primary-color-rgb), 0.3);
}

.card-glow {
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
    border-radius: inherit;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.algorithm-card-enhanced:hover .card-glow {
    opacity: 0.7;
}

.algorithm-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
}

.algorithm-icon-enhanced {
    font-size: 32px;
    margin-right: 15px;
}

.status-badge {
    padding: 6px 12px;
    border-radius: var(--border-radius-full);
    font-size: 11px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
}

.status-badge.implemented {
    background: linear-gradient(135deg, #00ff88, #00cc70);
    color: white;
}

.algorithm-details h3 {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 8px 0;
    color: var(--text-color);
}

.algorithm-description {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 15px;
    line-height: 1.5;
}

.formula-preview {
    background: rgba(0, 0, 0, 0.2);
    padding: 10px;
    border-radius: var(--border-radius-md);
    margin-bottom: 15px;
}

.formula-preview code {
    font-family: 'Courier New', monospace;
    color: var(--accent-color);
    font-size: 13px;
}

.performance-metrics {
    margin-bottom: 15px;
}

.metric-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.metric-name {
    font-size: 12px;
    color: var(--text-secondary);
}

.metric-badge {
    padding: 2px 6px;
    border-radius: var(--border-radius-sm);
    font-size: 10px;
    font-weight: 600;
}

.complexity-linear {
    background: #4facfe;
    color: white;
}

.convergence-medium {
    background: #ffd93d;
    color: #333;
}

.convergence-slow {
    background: #ff6b6b;
    color: white;
}

.convergence-fast {
    background: #6bcf7f;
    color: white;
}

.accuracy-stars {
    display: flex;
    gap: 2px;
}

.star {
    color: #ddd;
    font-size: 14px;
}

.star.active {
    color: #ffd700;
}

.algorithm-features {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.feature-tag {
    padding: 4px 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius-sm);
    font-size: 10px;
    color: var(--text-secondary);
}

/* 算法对比结果样式 */
.comparison-results-enhanced {
    margin-top: 30px;
}

.comparison-console {
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-lg);
    padding: 20px;
    margin-bottom: 25px;
}

.console-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.console-header h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    color: var(--text-color);
}

.console-actions {
    display: flex;
    gap: 10px;
}

.console-btn {
    padding: 8px 16px;
    border: none;
    border-radius: var(--border-radius-md);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.console-btn.primary {
    background: var(--primary-color);
    color: white;
}

.console-btn.secondary {
    background: var(--text-secondary);
    color: white;
}

.console-btn.accent {
    background: var(--accent-color);
    color: white;
}

.console-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.battle-parameters {
    margin-top: 15px;
}

.param-group label {
    display: block;
    font-size: 14px;
    color: var(--text-color);
    margin-bottom: 10px;
    font-weight: 500;
}

.intensity-selector {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.intensity-btn {
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--text-color);
    border-radius: var(--border-radius-md);
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 12px;
    font-weight: 500;
}

.intensity-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.intensity-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.battle-arena {
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-lg);
    padding: 25px;
    margin-bottom: 25px;
}

.arena-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.competitor {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius-lg);
    padding: 20px;
    transition: all 0.3s ease;
}

.competitor:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.competitor-header {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.competitor-avatar {
    font-size: 24px;
    margin-right: 12px;
}

.competitor-info {
    flex: 1;
}

.competitor-info h4 {
    margin: 0 0 4px 0;
    font-size: 16px;
    color: var(--text-color);
}

.competitor-type {
    font-size: 11px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.competitor-status {
    padding: 4px 8px;
    border-radius: var(--border-radius-sm);
    font-size: 10px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
}

.competitor-status.ready {
    background: #00ff88;
    color: #333;
}

.competitor-status.running {
    background: #ffd93d;
    color: #333;
}

.competitor-status.completed {
    background: var(--primary-color);
    color: white;
}

.competitor-metrics {
    margin-bottom: 15px;
}

.metric-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    font-size: 13px;
}

.metric-label {
    color: var(--text-secondary);
}

.metric-value {
    color: var(--text-color);
    font-weight: 600;
}

.progress-indicator {
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    width: 0%;
    transition: width 0.3s ease;
}

/* 成就系统重设计样式 */
.achievements-redesigned {
    padding: 0;
}

.achievements-header-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.floating-trophy {
    font-size: 48px;
    margin-bottom: 20px;
    animation: trophyFloat 3s ease-in-out infinite;
}

@keyframes trophyFloat {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-10px) rotate(5deg); }
}

.achievement-summary {
    display: flex;
    gap: 30px;
    margin-top: 20px;
    flex-wrap: wrap;
    justify-content: center;
}

.summary-metric {
    text-align: center;
}

.summary-metric .metric-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary-color);
    display: block;
}

.summary-metric .metric-label {
    font-size: 12px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.player-profile-section {
    margin-bottom: 40px;
    padding: 0 var(--section-padding);
}

.profile-card-enhanced {
    position: relative;
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-xl);
    padding: 30px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

.profile-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    opacity: 0.1;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
}

.profile-pattern {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: radial-gradient(circle at 25% 25%, rgba(255,255,255,0.1) 1px, transparent 1px);
    background-size: 20px 20px;
}

.profile-content {
    position: relative;
    display: flex;
    align-items: center;
    gap: 30px;
    flex-wrap: wrap;
}

.profile-avatar-enhanced {
    text-align: center;
}

.avatar-ring {
    position: relative;
    width: 100px;
    height: 100px;
    border: 3px solid var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
    background: linear-gradient(135deg, rgba(var(--primary-color-rgb), 0.2), rgba(var(--accent-color-rgb), 0.2));
}

.avatar-inner {
    position: relative;
    font-size: 36px;
    color: var(--primary-color);
}

.level-indicator {
    position: absolute;
    bottom: -5px;
    right: -5px;
    background: var(--accent-color);
    color: white;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
}

.rank-badge {
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    color: #333;
    padding: 6px 12px;
    border-radius: var(--border-radius-full);
    font-size: 12px;
    font-weight: 600;
}

.profile-info-enhanced {
    flex: 1;
    min-width: 200px;
}

.player-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-color);
    margin: 0 0 5px 0;
}

.player-subtitle {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.experience-system {
    margin-bottom: 20px;
}

.exp-bar-enhanced {
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 8px;
}

.exp-progress {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 4px;
    position: relative;
    transition: width 0.5s ease;
}

.exp-glow {
    position: absolute;
    top: -2px;
    right: -5px;
    width: 10px;
    height: 12px;
    background: radial-gradient(ellipse, rgba(var(--accent-color-rgb), 0.8), transparent);
    border-radius: 50%;
}

.exp-info {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 14px;
}

.current-exp, .max-exp {
    font-weight: 600;
    color: var(--text-color);
}

.exp-separator {
    color: var(--text-secondary);
}

.exp-label {
    color: var(--text-secondary);
    font-size: 12px;
}

.profile-stats-enhanced {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 15px;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--border-radius-md);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-icon {
    font-size: 18px;
}

.stat-item.primary .stat-icon { color: var(--primary-color); }
.stat-item.success .stat-icon { color: #00ff88; }
.stat-item.accent .stat-icon { color: var(--accent-color); }
.stat-item.warning .stat-icon { color: #ffd93d; }

.stat-data {
    flex: 1;
}

.stat-value {
    display: block;
    font-size: 16px;
    font-weight: 700;
    color: var(--text-color);
}

.stat-label {
    font-size: 11px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* 成就展示区域 */
.achievements-gallery {
    padding: 0 var(--section-padding);
    margin-bottom: 40px;
    position: relative;
    overflow: hidden;
}

/* 成就区域背景装饰 */
.achievements-gallery::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: 
        radial-gradient(circle at 20% 20%, rgba(var(--primary-color-rgb), 0.03) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(var(--accent-color-rgb), 0.03) 0%, transparent 50%),
        radial-gradient(circle at 40% 60%, rgba(var(--success-color-rgb), 0.02) 0%, transparent 40%);
    animation: backgroundFloat 20s ease-in-out infinite;
    z-index: 0;
}

@keyframes backgroundFloat {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    33% {
        transform: translate(50px, -30px) rotate(1deg);
    }
    66% {
        transform: translate(-30px, 40px) rotate(-0.5deg);
    }
}

.achievements-gallery > * {
    position: relative;
    z-index: 1;
}

/* 成就页面装饰性元素 */
.achievements-decoration {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.floating-element {
    position: absolute;
    font-size: clamp(16px, 2vw, 24px);
    opacity: 0.4;
    filter: blur(0.5px);
    animation: floatAround 15s infinite linear;
}

.floating-element.element-1 {
    top: 15%;
    left: 10%;
    animation-delay: -2s;
    animation-duration: 18s;
}

.floating-element.element-2 {
    top: 25%;
    right: 15%;
    animation-delay: -5s;
    animation-duration: 20s;
}

.floating-element.element-3 {
    bottom: 30%;
    left: 20%;
    animation-delay: -8s;
    animation-duration: 22s;
}

.floating-element.element-4 {
    top: 60%;
    right: 25%;
    animation-delay: -12s;
    animation-duration: 16s;
}

.floating-element.element-5 {
    bottom: 15%;
    right: 10%;
    animation-delay: -15s;
    animation-duration: 19s;
}

@keyframes floatAround {
    0% {
        transform: translateY(0px) rotate(0deg);
        opacity: 0.4;
    }
    25% {
        transform: translateY(-20px) rotate(90deg);
        opacity: 0.6;
    }
    50% {
        transform: translateY(-10px) rotate(180deg);
        opacity: 0.3;
    }
    75% {
        transform: translateY(-30px) rotate(270deg);
        opacity: 0.5;
    }
    100% {
        transform: translateY(0px) rotate(360deg);
        opacity: 0.4;
    }
}

.geometric-shape {
    position: absolute;
    opacity: 0.1;
    border: 2px solid var(--primary-color);
}

.geometric-shape.shape-triangle {
    top: 20%;
    left: 5%;
    width: 0;
    height: 0;
    border-left: 15px solid transparent;
    border-right: 15px solid transparent;
    border-bottom: 25px solid rgba(var(--primary-color-rgb), 0.1);
    border-top: none;
    animation: rotateShape 25s infinite linear;
}

.geometric-shape.shape-circle {
    top: 40%;
    right: 5%;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid rgba(var(--accent-color-rgb), 0.1);
    animation: pulseShape 8s infinite ease-in-out;
}

.geometric-shape.shape-hexagon {
    bottom: 25%;
    left: 8%;
    width: 30px;
    height: 17px;
    background: rgba(var(--success-color-rgb), 0.05);
    position: relative;
    animation: floatShape 12s infinite ease-in-out;
}

.geometric-shape.shape-hexagon:before,
.geometric-shape.shape-hexagon:after {
    content: "";
    position: absolute;
    width: 0;
    border-left: 15px solid transparent;
    border-right: 15px solid transparent;
}

.geometric-shape.shape-hexagon:before {
    bottom: 100%;
    border-bottom: 8.5px solid rgba(var(--success-color-rgb), 0.05);
}

.geometric-shape.shape-hexagon:after {
    top: 100%;
    border-top: 8.5px solid rgba(var(--success-color-rgb), 0.05);
}

.geometric-shape.shape-diamond {
    bottom: 40%;
    right: 12%;
    width: 20px;
    height: 20px;
    background: rgba(var(--warning-color-rgb), 0.05);
    transform: rotate(45deg);
    animation: spinShape 20s infinite linear;
}

@keyframes rotateShape {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes pulseShape {
    0%, 100% { 
        transform: scale(1); 
        opacity: 0.1; 
    }
    50% { 
        transform: scale(1.3); 
        opacity: 0.2; 
    }
}

@keyframes floatShape {
    0%, 100% { 
        transform: translateY(0px);
    }
    50% { 
        transform: translateY(-15px);
    }
}

@keyframes spinShape {
    0% { transform: rotate(45deg); }
    100% { transform: rotate(405deg); }
}

/* π值征服者区域样式优化 */
.player-title {
    font-size: 1.4rem !important; /* 缩小字体 */
    font-weight: 600 !important;
    color: var(--text-color) !important;
    margin-bottom: 8px !important;
    letter-spacing: 0.5px !important;
}

.player-subtitle {
    font-size: 0.9rem !important; /* 缩小副标题 */
    color: var(--text-secondary) !important;
    margin-bottom: 15px !important;
}

.profile-info-enhanced {
    padding: 15px !important; /* 减小内边距 */
}

.profile-card-enhanced {
    border-radius: 20px !important; /* 增加圆角 */
    max-width: 100% !important;
    margin-bottom: 25px !important;
    padding: 20px !important; /* 减少内边距 */
    transform: scale(0.95) !important; /* 整体缩小一点 */
}

.achievements-header-wrapper {
    text-align: center !important;
    padding: 15px 0 !important; /* 减少上下内边距 */
}

.achievement-summary {
    margin-top: 20px !important; /* 减小顶部间距 */
}

.achievement-summary .summary-metric {
    padding: 12px !important; /* 减小内边距 */
}

.page-header {
    margin-bottom: 20px !important; /* 减小底部间距 */
}

/* 成就殿堂头部增强样式 */
.achievement-motto {
    margin-top: 20px;
    text-align: center;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.motto-text {
    display: block;
    font-size: 0.95rem;
    color: var(--text-secondary);
    font-style: italic;
    line-height: 1.6;
    margin-bottom: 8px;
    position: relative;
}

.motto-text::before,
.motto-text::after {
    content: '"';
    font-size: 1.2rem;
    color: var(--accent-color);
    opacity: 0.7;
}

.motto-author {
    font-size: 0.8rem;
    color: var(--text-tertiary);
    text-align: right;
    font-weight: 500;
}

/* 统计指标增强样式 */
.summary-metric {
    position: relative;
    padding: 16px !important;
    text-align: center;
}

.metric-desc {
    display: block;
    font-size: 0.75rem;
    color: var(--text-tertiary);
    margin-top: 4px;
    font-weight: 400;
    opacity: 0.8;
}

.achievement-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin-top: 25px !important;
}

/* 玩家档案增强样式 */
.title-description {
    margin-top: 15px;
    padding: 12px;
    background: rgba(var(--primary-color-rgb), 0.05);
    border-radius: 12px;
    border-left: 3px solid var(--primary-color);
}

.title-description p {
    margin: 0 0 12px 0;
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
    font-style: italic;
}

.title-achievements {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.achievement-tag {
    font-size: 0.75rem;
    padding: 4px 8px;
    background: rgba(var(--accent-color-rgb), 0.15);
    color: var(--accent-color);
    border-radius: 12px;
    border: 1px solid rgba(var(--accent-color-rgb), 0.2);
    font-weight: 500;
}

/* 经验值系统增强样式 */
.exp-details {
    margin-top: 12px;
    padding: 10px;
    background: rgba(var(--success-color-rgb), 0.05);
    border-radius: 8px;
    font-size: 0.8rem;
}

.next-level-info {
    color: var(--text-secondary);
    margin-bottom: 8px;
    text-align: center;
}

.next-level-info strong {
    color: var(--success-color);
}

.exp-sources {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    justify-content: center;
}

.source-item {
    background: rgba(var(--warning-color-rgb), 0.1);
    color: var(--warning-color);
    padding: 2px 6px;
    border-radius: 8px;
    font-size: 0.7rem;
    font-weight: 500;
}

/* 成就中心响应式优化 */
@media (max-width: 768px) {
    .achievements-showcase-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .achievement-card-premium {
        padding: 20px;
    }
    
    .achievement-icon {
        font-size: 28px;
    }
    
    .floating-element {
        font-size: 14px;
        opacity: 0.3;
    }
    
    .geometric-shape.shape-circle {
        width: 25px;
        height: 25px;
    }
    
    .geometric-shape.shape-hexagon {
        width: 20px;
        height: 12px;
    }
    
    .geometric-shape.shape-diamond {
        width: 15px;
        height: 15px;
    }
}

@media (max-width: 480px) {
    .achievements-decoration {
        display: none; /* 在小屏幕上隐藏装饰元素 */
    }
    
    .achievement-card-premium {
        padding: 16px;
        margin-bottom: 16px;
    }
    
    .achievement-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .achievement-icon {
        font-size: 24px;
        margin-right: 0;
        margin-bottom: 8px;
    }
    
    .filter-chip {
        padding: 8px 12px;
        font-size: 12px;
    }
    
    .achievement-summary {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .title-achievements {
        justify-content: center;
    }
    
    .exp-sources {
        flex-direction: column;
        gap: 6px;
    }
    
    .motto-text {
        font-size: 0.85rem;
    }
    
    .title-description {
        padding: 10px;
        margin-top: 10px;
    }
}

.gallery-header {
    margin-bottom: 30px;
}

.achievement-filters-enhanced {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.filter-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: 
        linear-gradient(135deg, rgba(255, 255, 255, 0.15) 0%, rgba(255, 255, 255, 0.05) 100%),
        rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: var(--text-color);
    border-radius: var(--border-radius-full);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    font-size: 13px;
    font-weight: 500;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.filter-chip::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(255, 255, 255, 0.2) 50%, 
        transparent 100%);
    transition: left 0.5s ease;
}

.filter-chip:hover::before {
    left: 100%;
}

.filter-chip:hover {
    background: 
        linear-gradient(135deg, rgba(255, 255, 255, 0.25) 0%, rgba(255, 255, 255, 0.15) 100%),
        rgba(255, 255, 255, 0.2);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.filter-chip.active {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    border-color: var(--primary-color);
    color: white;
    box-shadow: 
        0 4px 16px rgba(var(--primary-color-rgb), 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.chip-icon {
    font-size: 14px;
}

.achievements-showcase-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
}

.achievement-card-premium {
    position: relative;
    background: 
        linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%),
        var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: 24px; /* 更大的圆角 */
    padding: 25px;
    box-shadow: 
        var(--shadow-lg),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    overflow: hidden;
}

/* 添加卡片内部装饰元素 */
.achievement-card-premium::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent 40%, rgba(255, 255, 255, 0.03) 50%, transparent 60%);
    transform: rotate(15deg);
    transition: all 0.6s ease;
    opacity: 0;
}

.achievement-card-premium:hover::after {
    animation: cardShimmer 1.5s ease-in-out;
}

@keyframes cardShimmer {
    0% {
        opacity: 0;
        transform: translateX(-100%) rotate(15deg);
    }
    50% {
        opacity: 1;
    }
    100% {
        opacity: 0;
        transform: translateX(200%) rotate(15deg);
    }
}

.achievement-card-premium.unlocked {
    border-color: var(--primary-color);
}

.achievement-card-premium.locked {
    opacity: 0.6;
    filter: grayscale(50%);
}

.achievement-card-premium:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 
        var(--shadow-xl),
        0 20px 40px rgba(0, 0, 0, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.achievement-glow {
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
    border-radius: inherit;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.achievement-card-premium.unlocked:hover .achievement-glow {
    opacity: 0.3;
}

.achievement-border {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    border-radius: 24px 24px 0 0; /* 匹配卡片的圆角 */
    overflow: hidden;
}

.achievement-border::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(255, 255, 255, 0.6) 50%, 
        transparent 100%);
    animation: borderShine 3s infinite;
}

@keyframes borderShine {
    0% {
        left: -100%;
    }
    100% {
        left: 100%;
    }
}

.achievement-card-premium.precision .achievement-border {
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
}

.achievement-card-premium.speed .achievement-border {
    background: linear-gradient(90deg, var(--accent-color), var(--warning-color));
}

.achievement-card-premium.explorer .achievement-border {
    background: linear-gradient(90deg, var(--primary-color), var(--success-color));
}

.achievement-card-premium.milestone .achievement-border {
    background: linear-gradient(90deg, var(--success-color), var(--warning-color));
}

.achievement-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
}

.achievement-icon {
    font-size: 36px;
    margin-right: 15px;
    position: relative;
    display: inline-block;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
    transition: all 0.3s ease;
    animation: iconGlow 3s ease-in-out infinite alternate;
}

.achievement-icon.legendary { 
    color: var(--primary-color);
    text-shadow: 0 0 20px rgba(var(--primary-color-rgb), 0.5);
}

.achievement-icon.epic { 
    color: var(--accent-color);
    text-shadow: 0 0 20px rgba(var(--accent-color-rgb), 0.5);
}

.achievement-icon.rare { 
    color: var(--success-color);
    text-shadow: 0 0 20px rgba(var(--success-color-rgb), 0.5);
}

.achievement-icon.common { 
    color: var(--warning-color);
    text-shadow: 0 0 15px rgba(var(--warning-color-rgb), 0.4);
}

@keyframes iconGlow {
    0% {
        filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
        transform: scale(1);
    }
    100% {
        filter: drop-shadow(0 4px 16px rgba(0, 0, 0, 0.4));
        transform: scale(1.05);
    }
}

.achievement-card-premium:hover .achievement-icon {
    transform: scale(1.1) rotate(5deg);
    animation-duration: 1s;
}

.achievement-rarity {
    padding: 6px 12px;
    border-radius: 20px; /* 更圆润的标签 */
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.achievement-rarity.legendary {
    background: var(--primary-color);
    color: white;
}

.achievement-rarity.epic {
    background: var(--accent-color);
    color: white;
}

.achievement-rarity.rare {
    background: var(--success-color);
    color: white;
}

.achievement-rarity.common {
    background: var(--warning-color);
    color: white;
}

.achievement-content {
    margin-bottom: 15px;
}

.achievement-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-color);
    margin: 0 0 8px 0;
}

.achievement-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 15px;
}

.achievement-progress {
    background: rgba(255, 255, 255, 0.1);
    height: 8px;
    border-radius: 12px; /* 更大的圆角 */
    overflow: hidden;
    margin-bottom: 10px;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.2);
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 12px; /* 匹配外层圆角 */
    transition: width 0.8s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
    overflow: hidden;
}

.progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, 
        rgba(255, 255, 255, 0.3) 0%, 
        rgba(255, 255, 255, 0.6) 50%, 
        rgba(255, 255, 255, 0.3) 100%);
    animation: progressShine 2s infinite;
    border-radius: 3px;
}

@keyframes progressShine {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

.progress-text {
    font-size: 11px;
    color: var(--text-secondary);
    display: block;
    margin-bottom: 10px;
}

.achievement-rewards {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 12px;
    background: rgba(var(--primary-color-rgb), 0.05);
    border-radius: 16px; /* 更大的圆角 */
    border: 1px solid rgba(var(--primary-color-rgb), 0.1);
    margin-top: 10px;
    position: relative;
    overflow: hidden;
}

.achievement-rewards::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(var(--accent-color-rgb), 0.1) 50%, 
        transparent 100%);
    transition: left 0.6s ease;
}

.achievement-card-premium:hover .achievement-rewards::before {
    left: 100%;
}

.reward-points {
    font-size: 13px;
    color: var(--accent-color);
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 6px;
}

.reward-points::before {
    content: '✨';
    font-size: 12px;
    animation: sparkle 2s infinite ease-in-out;
}

@keyframes sparkle {
    0%, 100% { opacity: 0.7; }
    50% { opacity: 1; }
}

.reward-title {
    font-size: 12px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 6px;
}

.reward-title::before {
    content: '🎁';
    font-size: 11px;
}

.achievement-timestamp {
    font-size: 11px;
    color: var(--text-secondary);
    opacity: 0.8;
}

.unlock-condition {
    font-size: 12px;
    color: var(--text-secondary);
    font-style: italic;
}

/* 进度概览面板 */
.progress-overview-section {
    padding: 0 var(--section-padding);
}

.overview-card {
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-xl);
    padding: 25px;
    box-shadow: var(--shadow-lg);
}

.overview-card h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 20px 0;
    color: var(--text-color);
    font-size: 18px;
}

.category-progress {
    margin-bottom: 20px;
}

.category-item {
    margin-bottom: 15px;
}

.category-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 6px;
    font-size: 13px;
}

.category-name {
    color: var(--text-color);
    font-weight: 500;
}

.category-count {
    color: var(--text-secondary);
}

.category-bar {
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
}

.bar-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.5s ease;
}

.bar-fill.precision { background: linear-gradient(90deg, #667eea, #764ba2); }
.bar-fill.speed { background: linear-gradient(90deg, #ffd93d, #ff6b6b); }
.bar-fill.explorer { background: linear-gradient(90deg, #4facfe, #00f2fe); }
.bar-fill.milestone { background: linear-gradient(90deg, #00ff88, #00cc70); }

.next-achievement {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
}

.next-achievement h4 {
    margin: 0 0 10px 0;
    color: var(--text-color);
    font-size: 16px;
}

.next-achievement-preview {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--border-radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.next-icon {
    font-size: 24px;
    color: var(--primary-color);
}

.next-info {
    flex: 1;
}

.next-title {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-color);
}

.next-progress {
    font-size: 12px;
    color: var(--text-secondary);
}

/* 3D可视化专用样式 */
.visualization-3d-main {
    padding: 0;
    display: grid;
    grid-template-columns: 300px 1fr 280px;
    gap: 20px;
    height: calc(100vh - 120px);
}

.title-3d-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.floating-cube {
    font-size: 48px;
    margin-bottom: 20px;
    animation: cubeFloat 4s ease-in-out infinite;
}

@keyframes cubeFloat {
    0%, 100% { transform: translateY(0) rotateY(0deg); }
    50% { transform: translateY(-15px) rotateY(180deg); }
}

.controls-3d-panel {
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-lg);
    padding: 20px;
    height: fit-content;
    box-shadow: var(--shadow-lg);
}

.panel-section {
    margin-bottom: 25px;
}

.panel-section:last-child {
    margin-bottom: 0;
}

.panel-section h3 {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 15px 0;
    color: var(--text-color);
    font-size: 16px;
    font-weight: 600;
}

.control-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.control-btn-3d {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 12px;
    border: none;
    border-radius: var(--border-radius-md);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.control-btn-3d.primary {
    background: var(--primary-color);
    color: white;
}

.control-btn-3d.secondary {
    background: var(--text-secondary);
    color: white;
}

.control-btn-3d.accent {
    background: var(--accent-color);
    color: white;
}

.control-btn-3d:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.view-options {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.view-preset {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px 8px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--border-radius-md);
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

.view-preset:hover {
    background: rgba(255, 255, 255, 0.2);
}

.view-preset.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.preset-icon {
    font-size: 16px;
    margin-bottom: 4px;
}

.view-preset span {
    font-size: 10px;
    font-weight: 500;
}

.parameter-row {
    margin-bottom: 15px;
}

.parameter-row label {
    display: block;
    font-size: 12px;
    color: var(--text-color);
    margin-bottom: 8px;
    font-weight: 500;
}

.param-control {
    display: flex;
    align-items: center;
    gap: 10px;
}

.range-3d {
    flex: 1;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
    outline: none;
    -webkit-appearance: none;
}

.range-3d::-webkit-slider-thumb {
    appearance: none;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
}

.range-3d::-moz-range-thumb {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    border: none;
}

.param-control span {
    font-size: 11px;
    color: var(--text-secondary);
    min-width: 40px;
    text-align: right;
}

.toggle-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toggle-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--text-color);
    cursor: pointer;
}

.toggle-label input[type="checkbox"] {
    display: none;
}

.toggle-slider {
    position: relative;
    width: 32px;
    height: 16px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    transition: background 0.3s ease;
}

.toggle-slider::before {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 12px;
    height: 12px;
    background: white;
    border-radius: 50%;
    transition: transform 0.3s ease;
}

.toggle-label input:checked + .toggle-slider {
    background: var(--primary-color);
}

.toggle-label input:checked + .toggle-slider::before {
    transform: translateX(16px);
}

.scene-3d-container {
    display: flex;
    flex-direction: column;
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.scene-wrapper {
    position: relative;
    flex: 1;
}

.threejs-container {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #0a0a0a, #1a1a2e);
}

.stats-overlay-3d {
    position: absolute;
    top: 20px;
    left: 20px;
    right: 20px;
    z-index: 10;
}

.stat-3d-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 12px;
    margin-bottom: 15px;
}

.stat-3d-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 15px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius-md);
}

.stat-icon-3d {
    font-size: 16px;
}

.stat-3d-item.primary .stat-icon-3d { color: var(--primary-color); }
.stat-3d-item.success .stat-icon-3d { color: #00ff88; }
.stat-3d-item.accent .stat-icon-3d { color: var(--accent-color); }
.stat-3d-item.warning .stat-icon-3d { color: #ffd93d; }

.stat-data {
    flex: 1;
}

.stat-data .stat-value {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: white;
    line-height: 1;
}

.stat-data .stat-label {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 2px;
}

.performance-info {
    display: flex;
    justify-content: center;
    gap: 20px;
    padding: 8px 15px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: var(--border-radius-md);
    font-size: 11px;
    color: rgba(255, 255, 255, 0.8);
}

.info-panel-3d {
    position: absolute;
    bottom: 20px;
    right: 20px;
    max-width: 300px;
    z-index: 10;
}

.info-toggle {
    width: 40px;
    height: 40px;
    background: rgba(0, 0, 0, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    font-size: 16px;
    margin-left: auto;
    margin-bottom: 10px;
    transition: all 0.3s ease;
}

.info-toggle:hover {
    background: var(--primary-color);
}

.info-content {
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius-lg);
    padding: 20px;
    color: white;
    display: none;
}

.info-content.show {
    display: block;
    animation: fadeInUp 0.3s ease;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.info-content h4 {
    margin: 0 0 10px 0;
    color: var(--primary-color);
    font-size: 16px;
}

.info-content p {
    font-size: 13px;
    line-height: 1.5;
    margin-bottom: 12px;
}

.formula-3d {
    background: rgba(255, 255, 255, 0.1);
    padding: 10px;
    border-radius: var(--border-radius-sm);
    font-family: 'Courier New', monospace;
    font-size: 12px;
    line-height: 1.4;
    margin-bottom: 12px;
}

.controls-hint {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.4;
}

.visualization-modes {
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-lg);
    padding: 20px;
    height: fit-content;
    box-shadow: var(--shadow-lg);
}

.visualization-modes h3 {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 15px 0;
    color: var(--text-color);
    font-size: 16px;
    font-weight: 600;
}

.mode-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.mode-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--border-radius-md);
    cursor: pointer;
    transition: all 0.3s ease;
}

.mode-card:hover {
    background: rgba(255, 255, 255, 0.2);
}

.mode-card.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.mode-preview {
    width: 32px;
    height: 32px;
    border-radius: var(--border-radius-sm);
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.mode-info {
    flex: 1;
}

.mode-info h4 {
    margin: 0 0 2px 0;
    font-size: 13px;
    font-weight: 600;
}

.mode-info p {
    margin: 0;
    font-size: 11px;
    opacity: 0.8;
}

/* 额外的教学系统样式 */
.title-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.floating-icon {
    font-size: 48px;
    margin-bottom: 20px;
    animation: floatBounce 3s ease-in-out infinite;
}

@keyframes floatBounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-15px); }
}

.progress-indicator {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

.progress-steps {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.step {
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--text-secondary);
    border-radius: var(--border-radius-full);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.step.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.step:hover:not(.active) {
    background: rgba(255, 255, 255, 0.2);
}

/* 教学模块 - 核心概念掌握样式 */
.learning-section {
    margin-bottom: 40px;
    padding: 0;
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    padding: 0 20px;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-color);
    margin: 0;
}

.icon-wrapper {
    font-size: 2rem;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
}

.difficulty-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.difficulty-badge.expert {
    background: linear-gradient(135deg, var(--accent-color), var(--accent-dark));
    color: white;
    box-shadow: 0 2px 8px rgba(236, 72, 153, 0.3);
}

.concept-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 24px;
    padding: 0 20px;
}

.concept-card {
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-lg);
    padding: 24px;
    box-shadow: var(--glass-shadow);
    transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
    overflow: hidden;
}

.concept-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.concept-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: var(--shadow-lg), 0 0 30px rgba(var(--primary-color-rgb), 0.15);
}

.concept-card:hover::before {
    opacity: 1;
}

.concept-card .card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.concept-card .card-icon {
    font-size: 2.5rem;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
}

.concept-card h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-color);
    margin: 0 8px;
    flex: 1;
}

.card-status {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
    background: rgba(var(--primary-color-rgb), 0.1);
    color: var(--primary-color);
    border: 1px solid rgba(var(--primary-color-rgb), 0.2);
}

/* 概率统计卡片特定样式 */
.statistical-theory-content {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 20px;
}

.probability-explanation,
.central-limit-theorem,
.variance-analysis {
    padding: 16px;
    background: rgba(var(--secondary-color-rgb), 0.05);
    border-left: 4px solid var(--secondary-color);
    border-radius: var(--border-radius);
}

.probability-explanation h4,
.central-limit-theorem h4,
.variance-analysis h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-color);
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.formula-box {
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid rgba(var(--primary-color-rgb), 0.2);
    border-radius: var(--border-radius);
    padding: 12px 16px;
    margin: 8px 0;
    font-family: 'Times New Roman', serif;
    font-size: 1.1rem;
    text-align: center;
    font-weight: 500;
    color: var(--text-color);
    box-shadow: var(--shadow-sm);
}

.insight-box {
    background: linear-gradient(135deg, rgba(var(--accent-color-rgb), 0.1), rgba(var(--accent-color-rgb), 0.05));
    border: 1px solid rgba(var(--accent-color-rgb), 0.2);
    border-radius: var(--border-radius);
    padding: 10px 12px;
    margin: 8px 0;
    font-size: 0.9rem;
    color: var(--text-color);
    font-style: italic;
}

.confidence-interval {
    background: rgba(var(--success-color-rgb), 0.1);
    border: 1px solid rgba(var(--success-color-rgb), 0.2);
    border-radius: var(--border-radius);
    padding: 8px 12px;
    margin: 8px 0;
}

.interval-formula {
    font-family: 'Times New Roman', serif;
    font-weight: 500;
    color: var(--success-color);
}

.variance-metrics {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 12px;
}

.variance-metrics .metric-card {
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(var(--primary-color-rgb), 0.1);
    border-radius: var(--border-radius);
    padding: 12px;
    text-align: center;
}

.variance-metrics .metric-title {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.variance-metrics .metric-formula {
    font-family: 'Times New Roman', serif;
    font-size: 0.9rem;
    color: var(--text-color);
    margin-bottom: 4px;
}

.variance-metrics .metric-value {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary-color);
}

/* 算法分析卡片特定样式 */
.algorithm-details {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.complexity-section,
.convergence-analysis,
.performance-metrics {
    padding: 16px;
    background: rgba(var(--warning-color-rgb), 0.05);
    border-left: 4px solid var(--warning-color);
    border-radius: var(--border-radius);
}

.complexity-section h4,
.convergence-analysis h4,
.performance-metrics h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-color);
    margin: 0 0 12px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.complexity-breakdown {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.complexity-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.7);
    border-radius: var(--border-radius);
    border: 1px solid rgba(var(--primary-color-rgb), 0.1);
}

.complexity-item.total {
    background: rgba(var(--primary-color-rgb), 0.1);
    border-color: var(--primary-color);
    font-weight: 600;
}

.complexity-label {
    font-size: 0.9rem;
    color: var(--text-color);
}

.complexity-value {
    font-family: 'Courier New', monospace;
    font-weight: 600;
    color: var(--primary-color);
    font-size: 1rem;
}

.complexity-desc {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-style: italic;
}

.convergence-details {
    background: rgba(255, 255, 255, 0.7);
    border-radius: var(--border-radius);
    padding: 12px;
}

.convergence-rate {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.rate-label {
    font-weight: 600;
    color: var(--text-color);
}

.rate-value {
    font-family: 'Courier New', monospace;
    font-weight: 700;
    color: var(--accent-color);
    font-size: 1.1rem;
}

.convergence-explanation p {
    margin-bottom: 8px;
    font-size: 0.9rem;
    color: var(--text-color);
}

.convergence-explanation ul {
    margin: 8px 0;
    padding-left: 20px;
}

.convergence-explanation li {
    margin-bottom: 4px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 12px;
}

.perf-metric {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: var(--border-radius);
    border: 1px solid rgba(var(--primary-color-rgb), 0.1);
}

.perf-metric .metric-icon {
    font-size: 1.5rem;
}

.perf-metric .metric-title {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 2px;
}

.perf-metric .metric-value {
    font-size: 1rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 2px;
}

.perf-metric .metric-note {
    font-size: 0.7rem;
    color: var(--text-tertiary);
}

.optimization-tips {
    padding: 16px;
    background: rgba(var(--success-color-rgb), 0.05);
    border-left: 4px solid var(--success-color);
    border-radius: var(--border-radius);
}

.optimization-tips h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-color);
    margin: 0 0 12px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.tips-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.tip-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.7);
    border-radius: var(--border-radius);
    border: 1px solid rgba(var(--success-color-rgb), 0.2);
}

.tip-icon {
    font-size: 1.2rem;
    flex-shrink: 0;
    margin-top: 2px;
}

.tip-content {
    font-size: 0.9rem;
    color: var(--text-color);
    line-height: 1.4;
}

.tip-content strong {
    color: var(--success-color);
    font-weight: 600;
}

/* 统计信息更新 */
.stats-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
    margin-top: 16px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: var(--border-radius);
}

.metric-item {
    text-align: center;
    padding: 8px;
}

.metric-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
    display: block;
}

.metric-value {
    font-size: 1rem;
    font-weight: 700;
    color: var(--primary-color);
}

/* 互动实验室样式增强 */
.experiment-meta {
    display: flex;
    align-items: center;
    gap: 20px;
}

.experiment-status {
    display: flex;
    align-items: center;
    gap: 10px;
}

.status-indicator {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary);
    padding: 4px 8px;
    background: rgba(var(--warning-color-rgb), 0.1);
    border-radius: 12px;
    border: 1px solid rgba(var(--warning-color-rgb), 0.2);
}

.status-dots {
    display: flex;
    gap: 4px;
}

.status-dots .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(var(--primary-color-rgb), 0.3);
    transition: all 0.3s ease;
}

.status-dots .dot.active {
    background: var(--primary-color);
    animation: pulse 1.5s ease-in-out infinite;
}

.experiment-controls {
    display: flex;
    gap: 8px;
}

.control-btn {
    padding: 8px 16px;
    border: none;
    border-radius: var(--border-radius);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.control-btn.primary {
    background: var(--primary-gradient);
    color: white;
    box-shadow: 0 2px 8px rgba(var(--primary-color-rgb), 0.3);
}

.control-btn.secondary {
    background: rgba(var(--text-secondary-rgb), 0.1);
    color: var(--text-secondary);
    border: 1px solid rgba(var(--text-secondary-rgb), 0.2);
}

.control-btn.accent {
    background: var(--accent-gradient);
    color: white;
    box-shadow: 0 2px 8px rgba(var(--accent-color-rgb), 0.3);
}

.control-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.experiment-workspace {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 24px;
    margin-top: 20px;
    padding: 0 20px;
}

.experiment-canvas-wrapper {
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-lg);
    padding: 20px;
    box-shadow: var(--glass-shadow);
    position: relative;
}

.canvas-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.canvas-header h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-color);
    margin: 0;
}

.canvas-tools {
    display: flex;
    gap: 4px;
}

.tool-btn {
    width: 32px;
    height: 32px;
    border: none;
    background: rgba(var(--primary-color-rgb), 0.1);
    border: 1px solid rgba(var(--primary-color-rgb), 0.2);
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tool-btn:hover {
    background: rgba(var(--primary-color-rgb), 0.2);
    transform: scale(1.1);
}

.canvas-overlay-enhanced {
    position: absolute;
    top: 60px;
    left: 20px;
    right: 20px;
    bottom: 20px;
    pointer-events: none;
    z-index: 10;
}

.coordinate-info {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 8px 12px;
    border-radius: var(--border-radius);
    font-family: 'Courier New', monospace;
    font-size: 0.8rem;
}

.distance-info {
    margin-top: 4px;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.8);
}

.real-time-stats {
    position: absolute;
    bottom: 10px;
    left: 10px;
    right: 10px;
}

.stat-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 8px;
    margin-bottom: 12px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: var(--border-radius);
    padding: 12px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.stat-card.primary {
    border-left: 4px solid var(--primary-color);
}

.stat-card.success {
    border-left: 4px solid var(--success-color);
}

.stat-card.accent {
    border-left: 4px solid var(--accent-color);
}

.stat-card.warning {
    border-left: 4px solid var(--warning-color);
}

.stat-card .stat-icon {
    font-size: 1.2rem;
    margin-bottom: 4px;
}

.stat-card .stat-number {
    display: block;
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 2px;
}

.stat-card .stat-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.stat-card .stat-trend {
    font-size: 0.7rem;
    color: var(--text-tertiary);
    font-family: 'Courier New', monospace;
}

.performance-stats {
    display: flex;
    justify-content: space-around;
    background: rgba(0, 0, 0, 0.8);
    border-radius: var(--border-radius);
    padding: 8px;
}

.perf-item {
    text-align: center;
}

.perf-label {
    font-size: 0.65rem;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
    display: block;
}

.perf-value {
    font-size: 0.9rem;
    color: white;
    font-weight: 600;
    font-family: 'Courier New', monospace;
}

.experiment-controls-panel {
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-lg);
    padding: 20px;
    box-shadow: var(--glass-shadow);
    height: fit-content;
}

.control-section {
    margin-bottom: 24px;
}

.control-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.control-title::before {
    content: '⚙️';
    font-size: 1rem;
}

.parameter-group {
    margin-bottom: 20px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: var(--border-radius);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.param-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}

.label-text {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-color);
}

.label-value {
    font-size: 0.8rem;
    color: var(--primary-color);
    font-weight: 600;
    background: rgba(var(--primary-color-rgb), 0.1);
    padding: 2px 8px;
    border-radius: 10px;
}

.param-control {
    position: relative;
}

.range-slider {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    outline: none;
    opacity: 0.8;
    transition: opacity 0.2s;
    background: linear-gradient(90deg, var(--accent-color) 0%, rgba(255,255,255,0.2) 0%);
}

.range-slider:hover {
    opacity: 1;
}

.range-slider::-webkit-slider-thumb {
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--accent-color);
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.range-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 4px;
    font-size: 0.7rem;
    color: var(--text-tertiary);
}

.styled-select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid rgba(var(--primary-color-rgb), 0.2);
    border-radius: var(--border-radius);
    background: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    color: var(--text-color);
    cursor: pointer;
    transition: all 0.3s ease;
}

.styled-select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(var(--primary-color-rgb), 0.2);
}

.display-modes {
    display: grid;
    grid-template-columns: 1fr;
    gap: 6px;
    margin-top: 8px;
}

.mode-btn {
    padding: 8px 12px;
    border: 1px solid rgba(var(--primary-color-rgb), 0.2);
    border-radius: var(--border-radius);
    background: rgba(255, 255, 255, 0.5);
    color: var(--text-color);
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mode-btn:hover {
    background: rgba(var(--primary-color-rgb), 0.1);
    border-color: var(--primary-color);
}

.mode-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.insight-panel {
    background: rgba(var(--accent-color-rgb), 0.05);
    border: 1px solid rgba(var(--accent-color-rgb), 0.2);
    border-radius: var(--border-radius);
    padding: 16px;
}

.insight-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.insight-content {
    margin-bottom: 16px;
}

.insight-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: var(--border-radius);
    margin-bottom: 8px;
    border-left: 3px solid var(--accent-color);
}

.insight-item.waiting {
    border-left-color: var(--warning-color);
}

.insight-icon {
    font-size: 1.1rem;
    flex-shrink: 0;
    margin-top: 2px;
}

.insight-text {
    font-size: 0.9rem;
    color: var(--text-color);
    line-height: 1.4;
}

.progress-analytics {
    margin-bottom: 16px;
}

.analytics-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 8px;
}

.convergence-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 6px;
}

.convergence-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--danger-color), var(--warning-color), var(--success-color));
    border-radius: 4px;
    transition: width 0.5s ease;
}

.convergence-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.experiment-history {
    margin-top: 16px;
}

.history-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 8px;
}

.history-list {
    max-height: 120px;
    overflow-y: auto;
}

.history-item {
    padding: 6px 10px;
    background: rgba(255, 255, 255, 0.4);
    border-radius: var(--border-radius);
    margin-bottom: 4px;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.history-item.placeholder {
    text-align: center;
    font-style: italic;
    color: var(--text-tertiary);
}

/* 互动实验室增强样式 */
.insight-item.info {
    border-left-color: var(--primary-color);
}

.insight-item.success {
    border-left-color: var(--success-color);
}

.insight-item.warning {
    border-left-color: var(--warning-color);
}

.insight-item.excellent {
    border-left-color: var(--secondary-color);
    background: linear-gradient(135deg, rgba(var(--secondary-color-rgb), 0.1), rgba(var(--secondary-color-rgb), 0.05));
}

.insight-item.perfect {
    border-left-color: var(--accent-color);
    background: linear-gradient(135deg, rgba(var(--accent-color-rgb), 0.1), rgba(var(--accent-color-rgb), 0.05));
    animation: perfectPulse 2s ease-in-out infinite;
}

@keyframes perfectPulse {
    0%, 100% { 
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    }
    50% { 
        box-shadow: 0 4px 16px rgba(var(--accent-color-rgb), 0.3);
        transform: scale(1.02);
    }
}

.status-dots .dot.completed {
    background: var(--success-color);
    animation: none;
}

.status-dots .dot.active {
    background: var(--primary-color);
    animation: pulse 1.5s ease-in-out infinite;
}

.history-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: var(--border-radius);
    margin-bottom: 6px;
    font-size: 0.8rem;
    color: var(--text-color);
    border-left: 3px solid var(--primary-color);
    transition: all 0.3s ease;
}

.history-item:hover {
    background: rgba(255, 255, 255, 0.8);
    transform: translateX(5px);
}

.history-time {
    font-weight: 600;
    color: var(--text-secondary);
}

.history-data {
    font-family: 'Courier New', monospace;
    color: var(--primary-color);
    font-weight: 600;
}

/* 画布工具栏增强 */
.canvas-tools {
    display: flex;
    gap: 6px;
}

.tool-btn {
    width: 32px;
    height: 32px;
    border: none;
    background: rgba(var(--primary-color-rgb), 0.1);
    border: 1px solid rgba(var(--primary-color-rgb), 0.2);
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
}

.tool-btn:hover {
    background: rgba(var(--primary-color-rgb), 0.2);
    transform: scale(1.1);
    box-shadow: 0 2px 8px rgba(var(--primary-color-rgb), 0.2);
}

.tool-btn:active {
    transform: scale(0.95);
}

/* 实验状态点增强 */
.status-dots {
    display: flex;
    gap: 6px;
}

.status-dots .dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(var(--primary-color-rgb), 0.3);
    transition: all 0.3s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* 收敛进度条样式 */
.convergence-bar {
    width: 100%;
    height: 10px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 5px;
    overflow: hidden;
    margin-bottom: 8px;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

.convergence-fill {
    height: 100%;
    background: linear-gradient(90deg, 
        var(--danger-color) 0%, 
        var(--warning-color) 50%, 
        var(--success-color) 80%, 
        var(--primary-color) 100%
    );
    border-radius: 5px;
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

/* 统计卡片趋势信息样式 */
.stat-trend {
    font-size: 0.7rem;
    color: var(--text-tertiary);
    font-family: 'Courier New', monospace;
    margin-top: 2px;
    font-weight: 500;
}

/* 显示模式按钮样式 */
.display-modes {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.mode-btn {
    flex: 1;
    min-width: 100px;
    padding: 10px 12px;
    border: 2px solid rgba(var(--primary-color-rgb), 0.2);
    background: rgba(var(--primary-color-rgb), 0.05);
    color: var(--text-color);
    border-radius: var(--border-radius);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.mode-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.mode-btn:hover::before {
    left: 100%;
}

.mode-btn:hover {
    border-color: var(--primary-color);
    background: rgba(var(--primary-color-rgb), 0.1);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(var(--primary-color-rgb), 0.3);
}

.mode-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(var(--primary-color-rgb), 0.4);
}

.mode-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(var(--primary-color-rgb), 0.3);
}

/* 画布叠加层增强 */
.coordinate-info {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.85);
    color: white;
    padding: 10px 14px;
    border-radius: var(--border-radius);
    font-family: 'Courier New', monospace;
    font-size: 0.8rem;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.coord-display {
    margin-bottom: 4px;
    font-weight: 600;
}

.distance-info {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.8);
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    padding-top: 4px;
    margin-top: 4px;
}

/* 3D视图容器样式 */
.threejs-container {
    width: 100%;
    height: 500px;
    min-height: 400px;
    position: relative;
    background: 
        radial-gradient(ellipse at top, rgba(var(--primary-color-rgb), 0.2), transparent),
        radial-gradient(ellipse at bottom, rgba(var(--accent-color-rgb), 0.1), transparent),
        linear-gradient(135deg, #0a0a0f, #1a1a2e);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    border: 2px solid rgba(var(--primary-color-rgb), 0.4);
    box-shadow: 
        0 8px 40px rgba(0, 0, 0, 0.6),
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        0 0 0 1px rgba(var(--primary-color-rgb), 0.2);
    position: relative;
}

.threejs-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 30% 30%, rgba(var(--accent-color-rgb), 0.1), transparent 50%),
        radial-gradient(circle at 70% 70%, rgba(var(--secondary-color-rgb), 0.08), transparent 50%);
    pointer-events: none;
    z-index: 1;
}

.threejs-container::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, var(--primary-color), var(--accent-color), var(--secondary-color), var(--primary-color));
    border-radius: var(--border-radius-lg);
    z-index: -1;
    opacity: 0.6;
    animation: borderGlow 4s ease-in-out infinite;
}

@keyframes borderGlow {
    0%, 100% {
        opacity: 0.6;
        filter: blur(1px);
    }
    50% {
        opacity: 0.8;
        filter: blur(2px);
    }
}

.threejs-container canvas {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    border-radius: var(--border-radius-lg);
    position: relative;
    z-index: 2;
}

.scene-3d-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--border-radius);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.scene-wrapper {
    position: relative;
    background: linear-gradient(135deg, #0f1419, #1a1a2e);
    border-radius: var(--border-radius);
    padding: 10px;
    box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.3);
}

.stats-overlay-3d {
    position: absolute;
    top: 15px;
    left: 15px;
    right: 15px;
    z-index: 10;
    pointer-events: none;
}

.stat-3d-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
    margin-bottom: 15px;
}

.stat-3d-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    border-radius: var(--border-radius);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.stat-3d-item.primary {
    border-color: var(--primary-color);
    box-shadow: 0 0 10px rgba(var(--primary-color-rgb), 0.3);
}

.stat-3d-item.success {
    border-color: var(--success-color);
    box-shadow: 0 0 10px rgba(var(--success-color-rgb), 0.3);
}

.stat-3d-item.accent {
    border-color: var(--accent-color);
    box-shadow: 0 0 10px rgba(var(--accent-color-rgb), 0.3);
}

.stat-3d-item.warning {
    border-color: var(--warning-color);
    box-shadow: 0 0 10px rgba(var(--warning-color-rgb), 0.3);
}

.stat-icon-3d {
    font-size: 16px;
    flex-shrink: 0;
}

.stat-data {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.stat-data .stat-value {
    font-size: 14px;
    font-weight: 700;
    color: white;
    font-family: 'Courier New', monospace;
}

.stat-data .stat-label {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
}

.performance-info {
    display: flex;
    gap: 15px;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.6);
    font-family: 'Courier New', monospace;
}

.info-panel-3d {
    position: absolute;
    bottom: 15px;
    right: 15px;
    z-index: 10;
}

.info-toggle {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(var(--primary-color-rgb), 0.8);
    border: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    color: white;
    font-size: 16px;
}

.info-toggle:hover {
    background: var(--primary-color);
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(var(--primary-color-rgb), 0.4);
}

.info-content {
    position: absolute;
    bottom: 45px;
    right: 0;
    width: 280px;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--border-radius);
    padding: 15px;
    color: white;
    font-size: 12px;
    line-height: 1.4;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    z-index: 20;
}

.info-content.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.formula-3d {
    background: rgba(var(--primary-color-rgb), 0.1);
    padding: 10px;
    border-radius: var(--border-radius);
    margin: 10px 0;
    border-left: 3px solid var(--primary-color);
    font-family: 'Courier New', monospace;
    font-size: 11px;
    line-height: 1.6;
}

.controls-hint {
    background: rgba(var(--accent-color-rgb), 0.1);
    padding: 10px;
    border-radius: var(--border-radius);
    margin-top: 10px;
    border-left: 3px solid var(--accent-color);
    font-size: 11px;
    line-height: 1.5;
}

/* 可视化模式选择器样式 */
.visualization-modes {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius);
    padding: 20px;
    margin: 20px 0;
    backdrop-filter: blur(10px);
}

.visualization-modes h3 {
    color: var(--text-color);
    font-size: 18px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.mode-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 15px;
}

.mode-card {
    background: rgba(255, 255, 255, 0.08);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius);
    padding: 15px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.mode-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s;
}

.mode-card:hover::before {
    left: 100%;
}

.mode-card:hover {
    border-color: var(--primary-color);
    background: rgba(var(--primary-color-rgb), 0.1);
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(var(--primary-color-rgb), 0.3);
}

.mode-card.active {
    border-color: var(--accent-color);
    background: rgba(var(--accent-color-rgb), 0.15);
    box-shadow: 0 4px 20px rgba(var(--accent-color-rgb), 0.4);
}

.mode-card.active::after {
    content: '✓';
    position: absolute;
    top: 10px;
    right: 10px;
    width: 20px;
    height: 20px;
    background: var(--accent-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
}

.mode-preview {
    width: 60px;
    height: 60px;
    margin: 0 auto 12px;
    border-radius: var(--border-radius);
    background: rgba(var(--primary-color-rgb), 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.mode-preview.heatmap-preview {
    background: linear-gradient(45deg, #ff6b35, #f7931e, #ffcc02);
}

.mode-preview.path-preview {
    background: linear-gradient(135deg, #00ff88, #00cc70);
}

.mode-preview.stats-preview {
    background: linear-gradient(180deg, #9d4edd, #7209b7);
}

.preview-sphere {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.6);
    background: rgba(255, 255, 255, 0.1);
}

.preview-points {
    position: absolute;
    color: rgba(255, 255, 255, 0.8);
    font-size: 12px;
    font-weight: bold;
    animation: pointsPulse 2s ease-in-out infinite;
}

@keyframes pointsPulse {
    0%, 100% { opacity: 0.6; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.1); }
}

.preview-gradient {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: linear-gradient(45deg, #ff0000, #ff8800, #ffff00);
    animation: gradientShift 3s ease-in-out infinite;
}

@keyframes gradientShift {
    0%, 100% { filter: hue-rotate(0deg); }
    50% { filter: hue-rotate(180deg); }
}

.preview-trail {
    color: rgba(255, 255, 255, 0.8);
    font-size: 18px;
    animation: trailMove 2s ease-in-out infinite;
}

@keyframes trailMove {
    0%, 100% { transform: translateX(-5px); opacity: 0.6; }
    50% { transform: translateX(5px); opacity: 1; }
}

.preview-chart {
    font-size: 24px;
    animation: chartBounce 2s ease-in-out infinite;
}

@keyframes chartBounce {
    0%, 100% { transform: scale(1) rotate(0deg); }
    50% { transform: scale(1.1) rotate(5deg); }
}

.mode-info {
    text-align: center;
}

.mode-info h4 {
    color: var(--text-color);
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
}

.mode-info p {
    color: var(--text-secondary);
    font-size: 12px;
    margin: 0;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .threejs-container {
        height: 350px;
        min-height: 300px;
    }
    
    .stat-3d-group {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .info-content {
        width: 220px;
    }
    
    .mode-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .mode-card {
        padding: 12px;
    }
    
    .mode-preview {
        width: 50px;
        height: 50px;
    }
}

/* 紧凑版可视化模式样式 - 用于3D控制面板 */
.visualization-modes-section {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
    margin-top: 20px;
}

.mode-grid-compact {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.mode-card-compact {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    padding: 10px 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    position: relative;
    overflow: hidden;
    min-height: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.mode-card-compact:hover {
    border-color: var(--primary-color);
    background: rgba(var(--primary-color-rgb), 0.1);
    transform: translateY(-1px);
}

.mode-card-compact.active {
    border-color: var(--accent-color);
    background: rgba(var(--accent-color-rgb), 0.15);
    box-shadow: 0 0 10px rgba(var(--accent-color-rgb), 0.3);
}

.mode-card-compact.active::after {
    content: '✓';
    position: absolute;
    top: 3px;
    right: 5px;
    color: var(--accent-color);
    font-size: 10px;
    font-weight: bold;
}

.mode-preview-compact {
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 6px;
    font-size: 14px;
}

.mode-info-compact span {
    font-size: 10px;
    color: var(--text-color);
    font-weight: 500;
    display: block;
    line-height: 1.1;
}

/* 紧凑预览元素样式 */
.mode-preview-compact .preview-sphere {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--primary-color);
    opacity: 0.8;
}

.mode-preview-compact .preview-points {
    color: var(--accent-color);
    font-size: 6px;
    margin-left: 2px;
}

.mode-preview-compact .preview-gradient {
    width: 16px;
    height: 12px;
    background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
    border-radius: 2px;
}

.mode-preview-compact .preview-trail {
    color: var(--primary-color);
    font-size: 10px;
    animation: trail-flow 2s ease-in-out infinite;
}

.mode-preview-compact .preview-chart {
    font-size: 12px;
    color: var(--accent-color);
}

@keyframes trail-flow {
    0%, 100% { opacity: 0.6; transform: translateX(-1px); }
    50% { opacity: 1; transform: translateX(1px); }
}

/* 底部信息区域样式 */
.bottom-info-section {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.operation-hints {
    background: rgba(var(--accent-color-rgb), 0.1);
    border: 1px solid rgba(var(--accent-color-rgb), 0.3);
    border-radius: 8px;
    padding: 12px 16px;
    color: var(--accent-color);
    font-size: 12px;
    font-weight: 500;
    text-align: center;
    opacity: 0.8;
}

/* 算法对比页面样式 - 简化版本 */
.comparison-redesigned {
    padding: 20px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--border-radius);
    margin: 20px 0;
}

.comparison-header-wrapper {
    text-align: center;
    margin-bottom: 30px;
}

.floating-algorithm-icon {
    font-size: 48px;
    margin-bottom: 15px;
    animation: floatIcon 3s ease-in-out infinite;
}

@keyframes floatIcon {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.page-description {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 30px;
}

.performance-dashboard {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-bottom: 40px;
}

.dashboard-metric {
    text-align: center;
}

.metric-value {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    font-family: 'Courier New', monospace;
}

.metric-label {
    display: block;
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-top: 5px;
}

/* 算法卡片网格 - 限制四种颜色 */
.algorithms-grid-enhanced {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.algorithm-card-enhanced {
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius);
    padding: 20px;
    position: relative;
    transition: all 0.3s ease;
    cursor: pointer;
}

.algorithm-card-enhanced:hover {
    border-color: var(--primary-color);
    background: rgba(var(--primary-color-rgb), 0.05);
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(var(--primary-color-rgb), 0.2);
}

.algorithm-card-enhanced.selected {
    border-color: var(--accent-color);
    background: rgba(var(--accent-color-rgb), 0.1);
    box-shadow: 0 4px 20px rgba(var(--accent-color-rgb), 0.3);
}

.card-glow {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: var(--border-radius);
    opacity: 0;
    background: radial-gradient(circle at center, rgba(var(--accent-color-rgb), 0.1), transparent);
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.algorithm-card-enhanced:hover .card-glow {
    opacity: 1;
}

.algorithm-header {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.algorithm-icon-enhanced {
    font-size: 2rem;
    margin-right: 15px;
}

.algorithm-details h3 {
    color: var(--text-color);
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.algorithm-description {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 15px;
    line-height: 1.5;
}

.formula-preview {
    background: rgba(var(--primary-color-rgb), 0.1);
    border: 1px solid rgba(var(--primary-color-rgb), 0.2);
    border-radius: var(--border-radius);
    padding: 12px;
    margin: 15px 0;
}

.formula-preview code {
    font-family: 'Courier New', monospace;
    color: var(--primary-color);
    font-size: 0.9rem;
    font-weight: 600;
}

/* 性能指标 - 限制颜色 */
.performance-metrics {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 15px 0;
}

.metric-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.metric-name {
    color: var(--text-color);
    font-size: 0.9rem;
    font-weight: 500;
}

.metric-badge {
    padding: 4px 10px;
    border-radius: var(--border-radius);
    font-size: 0.8rem;
    font-weight: 600;
    font-family: 'Courier New', monospace;
}

.complexity-linear {
    background: rgba(var(--primary-color-rgb), 0.2);
    color: var(--primary-color);
}

.convergence-medium {
    background: rgba(var(--accent-color-rgb), 0.2);
    color: var(--accent-color);
}

.convergence-slow {
    background: rgba(var(--warning-color-rgb), 0.2);
    color: var(--warning-color);
}

.convergence-fast {
    background: rgba(var(--success-color-rgb), 0.2);
    color: var(--success-color);
}

/* 精度星级 */
.accuracy-stars {
    display: flex;
    gap: 2px;
}

.star {
    color: rgba(255, 255, 255, 0.2);
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.star.active {
    color: var(--accent-color);
}

/* 特性标签 */
.algorithm-features {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 15px;
}

.feature-tag {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-color);
    padding: 4px 10px;
    border-radius: var(--border-radius);
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

/* 选择控制按钮 */
.selection-controls {
    display: flex;
    gap: 10px;
}

.selection-btn {
    background: rgba(var(--primary-color-rgb), 0.1);
    border: 1px solid rgba(var(--primary-color-rgb), 0.3);
    color: var(--primary-color);
    padding: 8px 16px;
    border-radius: var(--border-radius);
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.selection-btn:hover {
    background: rgba(var(--primary-color-rgb), 0.2);
    transform: translateY(-2px);
}

/* 竞技场控制台 */
.comparison-console {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius);
    padding: 20px;
    margin: 20px 0;
}

.console-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.console-header h3 {
    color: var(--text-color);
    font-size: 1.3rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.console-actions {
    display: flex;
    gap: 10px;
}

.console-btn {
    padding: 8px 15px;
    border: none;
    border-radius: var(--border-radius);
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
}

.console-btn.primary {
    background: var(--primary-color);
    color: white;
}

.console-btn.secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-color);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.console-btn.accent {
    background: var(--accent-color);
    color: white;
}

.console-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* 强度选择器 */
.intensity-selector {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.intensity-btn {
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: var(--border-radius);
    color: var(--text-color);
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.intensity-btn:hover, .intensity-btn.active {
    background: rgba(var(--primary-color-rgb), 0.2);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

/* 竞技场区域 */
.battle-arena {
    margin-top: 20px;
}

.arena-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
}

.competitor {
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius);
    padding: 15px;
    transition: all 0.3s ease;
}

.competitor.running {
    border-color: var(--primary-color);
    background: rgba(var(--primary-color-rgb), 0.1);
    animation: competitorPulse 2s ease-in-out infinite;
}

@keyframes competitorPulse {
    0%, 100% { box-shadow: 0 0 10px rgba(var(--primary-color-rgb), 0.3); }
    50% { box-shadow: 0 0 20px rgba(var(--primary-color-rgb), 0.6); }
}

.competitor-header {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

.competitor-avatar {
    font-size: 1.5rem;
    margin-right: 10px;
}

.competitor-info h4 {
    color: var(--text-color);
    font-size: 1rem;
    margin: 0;
}

.competitor-type {
    color: var(--text-secondary);
    font-size: 0.8rem;
}

.competitor-status {
    margin-left: auto;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 5px;
}

.competitor-status.ready {
    color: var(--success-color);
}

.competitor-status.running {
    color: var(--primary-color);
}

.competitor-status.finished {
    color: var(--accent-color);
}

.competitor-metrics {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin: 10px 0;
}

.metric-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
}

.metric-label {
    color: var(--text-secondary);
}

.metric-value {
    color: var(--text-color);
    font-family: 'Courier New', monospace;
    font-weight: 600;
}

.progress-indicator {
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
    margin-top: 10px;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    width: 0%;
    transition: width 0.3s ease;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .algorithms-grid-enhanced {
        grid-template-columns: 1fr;
    }
    
    .performance-dashboard {
        flex-direction: column;
        gap: 20px;
    }
    
    .console-actions {
        flex-direction: column;
        width: 100%;
    }
    
    .console-btn {
        width: 100%;
        justify-content: center;
    }
    
    .intensity-selector {
        flex-wrap: wrap;
    }
    
    .arena-grid {
        grid-template-columns: 1fr;
    }
}

/* 动态可视化图表样式 */
.visualization-dashboard {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
    margin-top: 30px;
}

.dashboard-section {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius);
    padding: 20px;
    position: relative;
}

.dashboard-section h3 {
    color: var(--text-color);
    font-size: 1.2rem;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.chart-container {
    width: 100%;
    height: 300px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: rgba(0, 0, 0, 0.2);
    border-radius: var(--border-radius);
    position: relative;
    overflow: hidden;
}

.chart-container canvas {
    max-width: 100%;
    max-height: 100%;
    border-radius: var(--border-radius);
}

.chart-legend {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 15px;
    flex-wrap: wrap;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: var(--text-color);
}

.legend-color {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid transparent;
}

.legend-item.monte-carlo .legend-color {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.legend-item.leibniz .legend-color {
    background: var(--accent-color);
    border-color: var(--accent-color);
}

.legend-item.nilakantha .legend-color {
    background: var(--success-color);
    border-color: var(--success-color);
}

.legend-item.buffon .legend-color {
    background: var(--warning-color);
    border-color: var(--warning-color);
}

/* 雷达图容器样式 */
.radar-container {
    width: 100%;
    height: 400px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: radial-gradient(circle at center, rgba(var(--primary-color-rgb), 0.1), transparent);
    border-radius: 50%;
    position: relative;
    overflow: hidden;
}

.radar-container canvas {
    max-width: 100%;
    max-height: 100%;
    border-radius: 50%;
}

/* 图表加载状态 */
.chart-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--text-secondary);
    font-size: 0.9rem;
    text-align: center;
}

.chart-loading::before {
    content: '';
    display: block;
    width: 40px;
    height: 40px;
    border: 3px solid rgba(var(--primary-color-rgb), 0.3);
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    animation: chartSpin 1s linear infinite;
    margin: 0 auto 10px;
}

@keyframes chartSpin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 性能雷达图样式增强 */
.performance-radar {
    display: flex;
    flex-direction: column;
}

.performance-radar .radar-container {
    flex: 1;
    min-height: 300px;
    background: 
        radial-gradient(circle at 30% 30%, rgba(var(--primary-color-rgb), 0.15), transparent 40%),
        radial-gradient(circle at 70% 70%, rgba(var(--accent-color-rgb), 0.1), transparent 40%),
        radial-gradient(circle at center, rgba(255, 255, 255, 0.05), transparent 60%);
}

/* 收敛性图表样式增强 */
.convergence-chart .chart-container {
    background: 
        linear-gradient(135deg, rgba(var(--primary-color-rgb), 0.05), rgba(var(--accent-color-rgb), 0.05)),
        rgba(0, 0, 0, 0.2);
}

/* 图表响应式设计 */
@media (max-width: 1200px) {
    .visualization-dashboard {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .radar-container {
        height: 300px;
    }
    
    .chart-container {
        height: 250px;
    }
}

@media (max-width: 768px) {
    .chart-legend {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .legend-item {
        justify-content: center;
    }
    
    .dashboard-section {
        padding: 15px;
    }
    
    .radar-container {
        height: 250px;
    }
    
    .chart-container {
        height: 200px;
    }
}

/* 算法详解样式 */
.algorithm-explanation {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.explanation-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius);
    padding: 20px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.explanation-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s;
}

.explanation-card:hover::before {
    left: 100%;
}

.explanation-card:hover {
    border-color: var(--primary-color);
    background: rgba(var(--primary-color-rgb), 0.05);
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(var(--primary-color-rgb), 0.2);
}

.explanation-card h3 {
    color: var(--text-color);
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.explanation-content p {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 12px;
}

.explanation-content strong {
    color: var(--text-color);
    font-weight: 600;
}

.complexity-analysis {
    background: rgba(var(--primary-color-rgb), 0.1);
    border: 1px solid rgba(var(--primary-color-rgb), 0.2);
    border-radius: var(--border-radius);
    padding: 15px;
    margin-top: 15px;
}

.complexity-item {
    color: var(--text-color);
    font-size: 0.9rem;
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
}

.complexity-item:last-child {
    margin-bottom: 0;
}

.complexity-item strong {
    color: var(--primary-color);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .algorithm-explanation {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .explanation-card {
        padding: 15px;
    }
    
    .explanation-card h3 {
        font-size: 1.1rem;
    }
}

/* 发展历程和前沿应用样式 */
.timeline-enhanced {
    position: relative;
    padding: 20px 0;
    margin: 0 20px;
}

.timeline-line {
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(to bottom, 
        var(--primary-color), 
        var(--accent-color), 
        var(--secondary-color)
    );
    transform: translateX(-50%);
    border-radius: 2px;
}

.timeline-milestone {
    position: relative;
    margin-bottom: 40px;
    display: flex;
    align-items: center;
    gap: 30px;
}

.timeline-milestone:nth-child(even) {
    flex-direction: row-reverse;
    text-align: right;
}

.timeline-milestone:nth-child(even) .milestone-content {
    text-align: left;
}

.milestone-marker {
    position: relative;
    z-index: 2;
    width: 80px;
    height: 80px;
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: 3px solid var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    transition: all 0.4s ease;
    flex-shrink: 0;
}

.milestone-marker:hover {
    transform: scale(1.1);
    box-shadow: 0 0 30px rgba(var(--primary-color-rgb), 0.4);
}

.milestone-origin .milestone-marker {
    border-color: var(--accent-color);
    background: linear-gradient(135deg, 
        rgba(var(--accent-color-rgb), 0.2), 
        rgba(var(--accent-color-rgb), 0.1)
    );
}

.milestone-development .milestone-marker {
    border-color: var(--secondary-color);
    background: linear-gradient(135deg, 
        rgba(var(--secondary-color-rgb), 0.2), 
        rgba(var(--secondary-color-rgb), 0.1)
    );
}

.milestone-expansion .milestone-marker {
    border-color: var(--warning-color);
    background: linear-gradient(135deg, 
        rgba(var(--warning-color-rgb), 0.2), 
        rgba(var(--warning-color-rgb), 0.1)
    );
}

.milestone-modern .milestone-marker {
    border-color: var(--success-color);
    background: linear-gradient(135deg, 
        rgba(var(--success-color-rgb), 0.2), 
        rgba(var(--success-color-rgb), 0.1)
    );
}

.marker-inner {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-color);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.milestone-content {
    flex: 1;
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-lg);
    padding: 24px;
    box-shadow: var(--glass-shadow);
    transition: all 0.4s ease;
    position: relative;
}

.milestone-content::before {
    content: '';
    position: absolute;
    top: 20px;
    width: 0;
    height: 0;
    border-style: solid;
}

.timeline-milestone:nth-child(odd) .milestone-content::before {
    left: -10px;
    border-width: 10px 10px 10px 0;
    border-color: transparent rgba(255, 255, 255, 0.2) transparent transparent;
}

.timeline-milestone:nth-child(even) .milestone-content::before {
    right: -10px;
    border-width: 10px 0 10px 10px;
    border-color: transparent transparent transparent rgba(255, 255, 255, 0.2);
}

.milestone-content:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg), 0 0 25px rgba(var(--primary-color-rgb), 0.15);
}

.milestone-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.milestone-header h3 {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-color);
    margin: 0;
}

.milestone-tag {
    padding: 4px 12px;
    border-radius: 16px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.milestone-tag.origin {
    background: var(--accent-gradient);
    color: white;
    box-shadow: 0 2px 6px rgba(var(--accent-color-rgb), 0.3);
}

.milestone-tag.theory {
    background: var(--secondary-gradient);
    color: white;
    box-shadow: 0 2px 6px rgba(var(--secondary-color-rgb), 0.3);
}

.milestone-tag.algorithm {
    background: var(--warning-color);
    color: white;
    box-shadow: 0 2px 6px rgba(var(--warning-color-rgb), 0.3);
}

.milestone-tag.modern {
    background: var(--success-color);
    color: white;
    box-shadow: 0 2px 6px rgba(var(--success-color-rgb), 0.3);
}

.milestone-content p {
    font-size: 1rem;
    color: var(--text-color);
    line-height: 1.6;
    margin-bottom: 12px;
}

.milestone-detail,
.milestone-achievement,
.milestone-impact {
    background: rgba(var(--primary-color-rgb), 0.05);
    border-left: 3px solid var(--primary-color);
    border-radius: var(--border-radius);
    padding: 10px 12px;
    margin-top: 12px;
    font-size: 0.9rem;
    color: var(--text-color);
}

.milestone-detail strong,
.milestone-achievement strong,
.milestone-impact strong {
    color: var(--primary-color);
    font-weight: 600;
}

.application-areas {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

.area-tag {
    padding: 4px 10px;
    background: rgba(var(--secondary-color-rgb), 0.1);
    color: var(--secondary-color);
    border: 1px solid rgba(var(--secondary-color-rgb), 0.2);
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.area-tag:hover {
    background: var(--secondary-color);
    color: white;
    transform: translateY(-2px);
}

/* 前沿应用样式 */
.applications-showcase {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 24px;
    margin-top: 20px;
    padding: 0 20px;
}

.application-category {
    background: var(--glass-background);
    backdrop-filter: blur(20px);
    border: var(--glass-border);
    border-radius: var(--border-radius-lg);
    padding: 24px;
    box-shadow: var(--glass-shadow);
    transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
    overflow: hidden;
}

.application-category::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.application-category:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg), 0 0 30px rgba(var(--primary-color-rgb), 0.15);
}

.application-category:hover::before {
    opacity: 1;
}

.application-category.finance::before {
    background: linear-gradient(90deg, #f59e0b, #f97316);
}

.application-category.physics::before {
    background: linear-gradient(90deg, #8b5cf6, #a855f7);
}

.application-category.ai::before {
    background: linear-gradient(90deg, #06b6d4, #0ea5e9);
}

.category-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.category-icon {
    font-size: 2rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.category-header h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-color);
    margin: 0;
    flex: 1;
}

.category-badge {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: rgba(var(--accent-color-rgb), 0.1);
    color: var(--accent-color);
    border: 1px solid rgba(var(--accent-color-rgb), 0.2);
}

.application-examples {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.example-item {
    background: rgba(255, 255, 255, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--border-radius);
    padding: 16px;
    transition: all 0.3s ease;
}

.example-item:hover {
    background: rgba(255, 255, 255, 0.7);
    transform: translateX(5px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.example-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.example-icon {
    font-size: 1.2rem;
}

.example-header strong {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-color);
}

.example-item p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 8px;
}

.example-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 8px;
}

.tech-tag {
    padding: 3px 8px;
    background: rgba(var(--primary-color-rgb), 0.1);
    color: var(--primary-color);
    border: 1px solid rgba(var(--primary-color-rgb), 0.2);
    border-radius: 10px;
    font-size: 0.7rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.tech-tag:hover {
    background: var(--primary-color);
    color: white;
    transform: scale(1.05);
}

/* 响应式适配 */
@media (max-width: 1024px) {
    .timeline-line {
        left: 30px;
    }
    
    .timeline-milestone {
        flex-direction: row !important;
        text-align: left !important;
        padding-left: 80px;
    }
    
    .timeline-milestone .milestone-content {
        text-align: left !important;
    }
    
    .timeline-milestone .milestone-content::before {
        left: -10px !important;
        right: auto !important;
        border-width: 10px 10px 10px 0 !important;
        border-color: transparent rgba(255, 255, 255, 0.2) transparent transparent !important;
    }
    
    .milestone-marker {
        position: absolute;
        left: -10px;
        width: 60px;
        height: 60px;
    }
    
    .applications-showcase {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .experiment-workspace {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .experiment-meta {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }
    
    .experiment-controls {
        justify-content: center;
    }
    
    .stat-group {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .performance-stats {
        flex-direction: column;
        gap: 8px;
    }
    
    .concept-cards-grid {
        grid-template-columns: 1fr;
    }
}

/* 增强的可视化效果 */
.visual-demonstration {
    display: flex;
    gap: 30px;
    align-items: flex-start;
    flex-wrap: wrap;
}

.geometry-container {
    flex: 1;
    min-width: 200px;
}

.unit-square.enhanced {
    position: relative;
    width: 200px;
    height: 200px;
    border: 2px solid var(--primary-color);
    border-radius: var(--border-radius-md);
    margin: 0 auto 20px auto;
    background: linear-gradient(135deg, 
        rgba(var(--primary-color-rgb), 0.1), 
        rgba(var(--accent-color-rgb), 0.1)
    );
    overflow: hidden;
}

.inscribed-circle.pulsing {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 196px;
    height: 196px;
    border: 2px solid var(--accent-color);
    border-radius: 50%;
    animation: circlePulse 3s ease-in-out infinite;
}

@keyframes circlePulse {
    0%, 100% { opacity: 0.8; transform: translate(-50%, -50%) scale(1); }
    50% { opacity: 1; transform: translate(-50%, -50%) scale(1.02); }
}

.grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        linear-gradient(rgba(255,255,255,0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.1) 1px, transparent 1px);
    background-size: 20px 20px;
    opacity: 0.5;
}

.demo-points-enhanced {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.coordinate-labels {
    position: absolute;
    color: var(--text-secondary);
    font-size: 11px;
    font-weight: 500;
}

.coord-label.top-right {
    top: -25px;
    right: -10px;
}

.coord-label.bottom-left {
    bottom: -25px;
    left: -10px;
}

.formula-derivation {
    flex: 1;
    min-width: 250px;
}

.formula-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 15px;
    text-align: center;
}

.formula-steps-enhanced {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.step-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius-md);
    transition: all 0.3s ease;
}

.step-item:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateX(5px);
}

.step-item.conclusion {
    background: rgba(var(--accent-color-rgb), 0.2);
    border-color: var(--accent-color);
}

.step-badge {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    flex-shrink: 0;
}

.step-item.conclusion .step-badge {
    background: var(--accent-color);
}

.step-formula {
    flex: 1;
}

.step-formula .latex {
    font-family: 'KaTeX_Math', 'Times New Roman', serif;
    font-size: 14px;
    color: var(--text-color);
}

.step-formula.highlight .latex {
    color: var(--accent-color);
    font-weight: 600;
    font-size: 16px;
}

/* 响应式设计优化 */
@media (max-width: 1024px) {
    .visualization-3d-main {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto 1fr auto;
        height: auto;
        gap: 15px;
        padding: 15px;
    }
    
    .controls-3d-panel {
        order: 1;
    }
    
    .scene-3d-container {
        order: 2;
        height: 60vh;
        min-height: 400px;
    }
    
    .visualization-modes {
        order: 3;
    }
}

@media (max-width: 768px) {
    .floating-cube, .floating-algorithm-icon, .floating-trophy, .floating-icon {
        font-size: 32px;
    }
    
    .control-grid {
        grid-template-columns: 1fr;
    }
    
    .stat-3d-group {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .visual-demonstration {
        flex-direction: column;
        align-items: center;
    }
    
    .unit-square.enhanced {
        width: 160px;
        height: 160px;
    }
    
    .inscribed-circle.pulsing {
        width: 156px;
        height: 156px;
    }
}